Let $F$ be a field. Why is $\frac{F[x]}{(x-1)}\oplus \frac{F[x]}{(x-1)}$ not isomorphic to $\frac{F[x]}{(x-1)^2}$ as $F[x]$-modules?
My initial thought was to say the direct sum is generated by 2 elements but the other one is generated by 1. Is there any truth to this line of thinking?
If $R/I\times R/I\simeq R/I^2$ as $R$-modules, then they have the same annihilator, so $I=I^2$ (which in your example is not the case).