in which 在此可否用 when 代替?

有一读者问: 有这样一道选择题:

He told the nurse his name and the year_________he was in hospital.

A. in which B. which

C. in that D. where

答案是 in which。 in which 在此起什么作用?可否用 when 代替?

in which 在此是一状语短语, which 是关系代词,其先行词是 the year。 这里亦可用 when,但不像 in which那样正式。