Why is self-intersection not allowed with continuous transformations?

Self-intersection would mean $f$ is not bijective - two points map to the same point. I will try to give an example.

Imagine a line of length one, say the interval $[0,1]$. This is very easily bijective with the letter $U$, simply by "curving" the unit line. However, let us say we continue curving the sides of $U$ until they intersect, forming some sort of upright $\alpha$. If we keep our transformation from $[0,1]$ in mind, and starting from one end of our $\alpha$, when we pass the intersection point the first time, we could associate some number from the interval $[0,1]$, corresponding to how far we have walked. Say, $\frac13$. Now, we keep walking, and the next time we pass the intersection point, we may assign a new number to the intersection, say $\frac23$. This walk is supposed to be our homeomorphy from $\alpha$ to $[0,1]$, but as we have seen, it is not injective, thus not bijective: Indeed, $f(\frac13)=f(\frac23)=*$, where $*$ is the intersection point.

This indicates that closed loops are intrinsic and an important property - which will become apparent when you start looking at fundamental groups and homotopy.