You are supposed to show that $h(x)=0$ for some $x\in [0,1]$. In order to do so, you can use the fact that $h$ is a continuous function and apply the intermediate value theorem. Note that $h(0)=f(0)\geq 0$ and $h(1)=f(1)-1\leq 0$, so by the IVT we have some $x\in [0,1]$ such that $h(x)=0$, so $f(x)=x$.
Edit: A more general approach using more advanced techniques allows us to show that for any continuous function $f:[a,b]\to [a,b]$ and non-intersection continuous curve $\gamma:[0,1]\to [a,b]\times [a,b]$ such that $\gamma(0)=(a,a),\gamma(1)=(b,b)$, there exists some $t\in [0,1],x\in [a,b]$ such that $(x,f(x))=\gamma(t)$. This is a proper generalization of the original question, which is equivalent to letting $a=0,b=1$ and defining $\gamma(t)=(t,t)$. Assume $f(a)> a$ as otherwise we are done. By the Jordan curve theorem, the regions $A$ above and $B$ below the curve $\gamma$ are connected yet $A\cup B$ is disconnected. Let $\Gamma(f)$ denote the graph of $f$. Note that $\Gamma(f)\cup A\cup B$ is connected, as each term is connected, $(a,f(0))\in \Gamma(f)\cap A$ and either $f(b)<b$ in which case $(b,f(b))\in \Gamma(f)\cap B$ or $f(b)=b$ in which case $(b,b)\in \Gamma(f)\cap (B\cup (b,b))$ and it is easy to verify that $B\cup (b,b)$ is connected. Thus $\Gamma(f)\cup A\cup B\neq A\cup B$ so we have some $(x,f(x))\in ([a,b]\times [a,b])\setminus (A\cup B)=\gamma$.