Stellantis for example knew about the problem of their engine blowing up since before 2020, but they chose to ignore it. Small turbocompressed engines are or new at this point and how to make them reliable is known too.
Or take VW, cheating before 2015 so regulation is not an excuse, and since a decade most failures are parts like coolant circuits because of cheap plastic, gearboxes, and a lot of non safety related electronics features. And what is the replacement for family mmovers? Luxury SUVs or 75k€ iD Buzz.
Edit: So in short multiple things can be true: legal reasons for price increases, but also bad marketing choices.
Edit2: actual study showing at least half the price increase was chosen: https://institut-mobilites-en-transition.org/publications/le...