This is an extremely reductive take based on anecdote.
There are a lot of reasons people can feel lonely. Hell you can even feel lonely when you have deep meaningful relationships. Sometimes it's a result of anxiety or depression, or an abusive relationship.
Of course some people fall into the category you speak of too.