The following argument is essentially an application of the path lifting property for covering spaces.
Let's think about $\mathbb{R}P^2$ as being the quotient space you get by identifying antipodal points on the sphere $S^2$. That is, let $x\sim -x$, let $\mathbb{R}P^2=S^2/\sim$ and let $p\colon S^2\rightarrow\mathbb{R}P^2$ be the quotient map. Let $z$ be the base point of $S^2$ and $y$ be the base point of $\mathbb{R}P^2$.
Now, consider a non-trvial loop $\gamma\colon[0,1]\rightarrow\mathbb{R}P^2$ based at the point $y\in\mathbb{R}P^2$ (so $\gamma$ can not be homotoped to a constant loop). Note that the preimage of $y$ under $p$ is exactly two points in $S^2$ which are $z$ and $-z$. If we lift the loop $\gamma$ up to $S^2$ via the lift $\tilde{p}$, the end points of the lifted path $\tilde{\gamma}\colon[0,1]\rightarrow S^2$ will either both be at $z$, or $\tilde{\gamma}(0)=z$ and $\tilde{\gamma}(1)=-z$.
But note that if both end points are at $z$, then $\tilde{\gamma}$ is a loop and we know that $S^2$ is simply connected so such a loop can be homotoped to a constant loop. Such a homotopy induces a similar homotopy in the loop $\gamma$ and so $\gamma$ must be trivial. This is a contradiction as we asked for $\gamma$ to be non-trivial. So, $\tilde{\gamma}(0)=z$ and $\tilde{\gamma}(1)=-z$.
Now, in this case, the path $\tilde{\gamma}$ can not be homotoped to a constant loop without moving the fixed ends of the path but if we consider the lift of the path $2\gamma$ via $\tilde{p}$, then the lifted path $\tilde{2\gamma}$ is a loop in $S^2$. Again, $S^2$ is simply connected and so such a loop can be homotoped to a constant loop and such a homotopy induces a similar homotopy in the loop $2\gamma$ and so $2\gamma$ is a trivial loop.