I don't understand the meaning of "in the first place" in this sentence:

"Many believe that it would be better to spend more preventing people from becoming unwell in the first place, and reduce the amount spent on curing ill help"

I looked it up in oxford dictionary and i got this "
in the first place -> used at the end of a sentence to talk about why sth was done or whether it should have been done or not " but i'm still not sure if it means so in the context above.

if possibe, please give me some other examples.

AnonymousI don't understand the meaning of "in the first place" in this sentence
before the negative consequences of the situation occur(red).

-- I'm having a lot of trouble with the used car I bought.
-- Why did you buy a used car?
-- I was trying to save money.
-- But now you've paid a lot of money for repairs. You should have bought a new car in the first place. Then you wouldn't have had so much trouble.

-- The paint on my house looks terrible.
-- Did you follow the instructions for using that kind of paint?
-- Not really. I thought I could get it done faster my way. Now I'll have to do it over again.
-- That wouldn't have happened if you had done it right in the first place.

A phrase with the same meaning: to begin with.