According to the Red Cross, there are about 6635 homeless people in Denmark, out of a population of 5.7 million. That’s a bit more than 1 out of 1000 Danes.
A local homeless organization puts the number at about double that, if you account for people who are homeless at some time during the year, but not all the time.
Homelessness probably increases in the summer, and many of the homeless are not Danish, which means they are not eligible for most of the places in Denmark’s network of homeless shelters.
Begging is illegal in Denmark, although it sometimes takes place in city trains. Homeless people do stand outside supermarkets selling a newspaper about their lives and interests, Hus Forbi.
Bottom line: your question is based on a false premise. There are plenty of visible homeless people in Denmark.
In addition, Denmark is not a socialist economy - it is a capitalist one, with more privatization than is common in many parts of the US. (City buses are privately operated, for example.)