Here is a standard example (which you can find also in the big book of Demailly) in the complex category with the language of sheaves which perhaps may be of some interest for you.
Take $X=\mathbb C^3$, $\mathcal F=\mathcal O^{\oplus 3}$, $\mathcal G=\mathcal O$ and
$$
\varphi\colon\mathcal O^{\oplus 3}\to\mathcal O,\quad (u_1,u_2,u_3)\mapsto\sum_{j=1}^3z_j\,u_j(z_1,z_2,z_3).
$$
Since $\varphi$ yelds a surjective bundle morphism on $\mathbb C^3\setminus\{0\}$, it is easy to see taht $\ker\varphi$ is locally free of rank $2$ over $\mathbb C^3\setminus\{0\}$. However, by looking at the Taylor expansion of the $u_j$'s at $0$, you can check that $\ker\varphi$ is the $\mathcal O$-submodule of $\mathcal O^{\oplus 3}$ generated by the three sections $(-z_2,z_1,0)$, $(-z_3,0,z_1)$ and $(0,z_3,-z_2)$, and that any two of these three sections cannot generate the $0$-stalk $(\ker\varphi)_0$.
Thus, $\ker\varphi$ is not locally free.
On the other hand, if you have a surjective bundle morphism, the kernel is always locally free.