The idea is when everyone pays into insurance the collective fund is used to pay for the costs any individual wouldn’t.
Thankfully accidents or thefts don’t happen to everyone, but if they do you usually get more out than you put in (personal liability is usually millions of dollars, nobody puts that much in individually).
Where this goes wrong is when fraud happens or insurance companies are incentivized to manipulate rates to increase their profits.