The statement you want is (without further hypotheses on $f$) false - this was observed by Cantor, and is similar to how there is a bijection between $\mathbb{N}$ and $\mathbb{N}\times\mathbb{N}$. See for example the discussion here.
- As a quick explanation of why such a thing might be expected, consider the "interleaving" map $i:[0,1)^2\rightarrow [0,1)$ gotten by interleaving the non-trailing-$9$s decimal expansions of the inputs - e.g. $$i(0.101010..., 0.3333...)=0.13031303...$$ This isn't quite what you want, but it is a bijection. Now how different are $[0,1]$ (which is what Cantor originally phrased his theorem about, if I recall correctly), $[0,1)$, and $\mathbb{R}$ really (that is, in terms of cardinality)?
Now, if you demand that $f$ be continuous, you do indeed get what you want (as a corollary of invariance of domain). But there are in fact bijections between $\mathbb{R}^m$ and $\mathbb{R}^n$ for all integers $m,n>1$.