Artillery had become a niche branch in the Western doctrine, and people didn't see a point in investing in large-scale shell production. Air forces and guided missiles had replaced artillery in many of its traditional roles.
In the Soviet doctrine, artillery had a much larger role. Both Russia and Ukraine inherited that doctrine, and they went on to fight the war they were prepared for.