Most social programs are like insurance. You pay in when you don't need it, and it's there for you when you do need it.
When my kids were young and I was poor, other people paid for their schooling. Now the kids are out of school, but I'm paying for public schools for other kids.
If you make social programs voluntary, then people join when they need it and quit when they don't.
That's why you can't buy fire insurance for your house only when it's burning. You have to buy the insurance when it's not on fire, or the entire program doesn't work.