$$\textbf{Step -1: Using remainder theorem to get the following equations.}$$
$$\text{Given, Dividing }f(z) \text{ by } z - i \text{, we get remainder }i$$
$$\text{Therefore by remainder theorem, }f(i) = i$$ $$\dots \text{(i)}$$
$$\text{Given, Dividing }f(z) \text{ by } z + i \text{, we get remainder }1 + i$$ $$\text{Therefore by remainder theorem, }f(-i) = 1+i$$ $$\dots \text{(ii)}$$
$$\text{Let }R(x) \text{ be the remainder when }f(z)\text{is divided by }z^2 + 1$$
$$\text{degree of R(z) is 1, hence }R(z) = az+b$$
$$\text{we can simplify }z^2 + 1 = (z -i) (z+i)$$
$$\therefore f(z) = Q(z)(z-i)(z+i) + R(z)$$
$$\textbf{Step -2: Solving for a and b.}$$
$$\text{From (i) and (ii)}$$
$$f(i) = i = ai + b$$
$$\Rightarrow b = i - ai$$
$$f(-i) = 1+i = -ai +b$$
$$\Rightarrow -ai + i - ai = 1+i$$
$$\Rightarrow -2ai = 1$$
$$\Rightarrow a = -\dfrac{1}{2i}$$
$$= -\dfrac{1}{2i} \times \dfrac{i}{i}$$
$$= -\dfrac{i}{2(-1)}$$
$$\therefore a = \dfrac{i}{2}$$
$$ b = i - ai$$
$$\Rightarrow b = i - \dfrac{i}{2} (i)$$
$$\Rightarrow b = i - \dfrac{(-1)}{2}$$
$$\Rightarrow b = i + \dfrac{1}{2}$$
$$\therefore R(z) = az+b$$ $$= \dfrac{i}{2}z + i + \dfrac{1}{2}$$
$$R(z) = \dfrac{1}{2}(iz + 1) + i$$
$$\textbf{Hence option B is correct}$$