Suppose $R$ is a ring with unity and $f:R\to R'$ is a ring homomorphism. Then, $f(R)$ must have an identity $1_{f(R)}.$ But $1_{f(R)}$ may not be the identity of $R'$. Even $R'$ may not contain any identity. Suppose $R'$ contains $1_{R'};$ even still, the ring homomorphism may not necessarily map $1_R$ to $1_{R'}.$
Why does this occur? I am unable to find exactly why it is so. Can this be explained by semigroup homomorphisms or monoid homomorphisms, i.e., maps from semigroup $S_1$ to $S_2$ such that $f(a \cdot b)=f(a) \cdot f(b)$?