In much simpler terms (eschewing more complex reasoning about 2nd strikes etc. specific to nuclear weapons): being able to hit your enemy without them being able to hit you back is a good recipe for winning a war. It's why the US (and in fact anyone else who can) pursues technological superiority, including in defensive tech, be it tank armor, CIWS, stealth in planes/drones and what not.
For a somewhat modern [theater] example, consider the "SAM umbrella" that allowed Arab armies to advance during the initial phase of the 1973 war because it negated to some extent the Israeli airforce.
Finally, you say
It seems to me like a world where defensive weapons are a lot stronger than offensive ones would be a way to achieve the long-term goal of preventing war, since it precludes countries from attacking each other.
But the catch is that we don't live in that technological utopia. A bullet is a lot harder to hit than a man. A city is far easier to hit than a missile (targeting it). Etc. Physics and biology conspire against your plan for impenetrable defenses, except in highly [technologically] lopsided scenarios like Gaza/Hamas vs Israel, in which only one side has the shield working. If you want me to put it bluntly, Russia fears that in a nightmare scenario it will end up like Gaza in a sense, i.e. unable to break through a technologically and possibly numerically superior defense as well, while it's still vulnerable to attack. (Of course, they are also exaggerating how real/near that kind of perspective is, given the current state of nuclear arsenals relative to interceptors etc.)
Russia understands this equation fairly well, which is why you see them counter with announcements of and (for now) small scale deployments of stuff that can bypass would-be defenses: hypersonic glide vehicles (Avangard), unmanned nuclear-powered autonomous torpedos (Poseidon), etc.
Basically, in an economically imbalanced arms race, one side will go for the offensive weapons, because it's the [only] way to (potentially) prevail over an economically superior foe. Think how the Taliban prevailed over the US: it wasn't by building some shield to stop all US missiles, bombs, planes, drones etc. Instead they got better at building IEDs and deploying them in larger numbers and also adopted (and scaled up) suicide attacks, their cheapo version of a stealth/guided "missile" that could make it through defenses.