Why is $(X,Y)$ not a projective $\mathbb{Z}[X,Y]$-module?
Let $R=\mathbb Z[X,Y]$ and $I=(X,Y)$. There is a short exact sequence of left $R$-modules $$0\to R\xrightarrow{f} R\oplus R\xrightarrow{g}I\to 0$$ with $f(a)=(Ya,-Xa)$ and $g(a,b)=aX+bY$ for all $a$, $b\in R$.
Check that it doesn't split.
Let's write $R=\mathbf Z[X,Y]$, $I=(X,Y)$. Two strategies:
First strategy: Let $M$ be the free $R$-module of rank $2$, with generators $u$ and $v$. Consider the exact sequence
$$0 \to K \to M \to I \to 0 $$
where $u \mapsto X$, $v \mapsto Y$, and $K$ is the kernel. Prove that $K$ is free of rank $1$, generated by $Yu-Xv$. Then prove that the sequence is not split on the left. (In a splitting $M\to K$, where could $u$ and $v$ go? Look at degrees of polynomials...)
Second strategy: Prove that $I$ is not flat. Can you find an ideal $J\subseteq R$ such that the natural map $J\otimes_R I \to I$ is not injective?