It can feel easier to share personal thoughts with someone you barely know rather than close friends. Maybe there’s less fear of judgment. Why do you think that happens? Have you ever had a surprisingly deep conversation with a stranger?
I think it's fear of judgement. The stranger knows nothing about you, so people might find comfort in that. Also in most cases you're not going to see this stranger again, and if people know that they'll probably me more likely to say whatever it is they want to say.
I think it is simply based on the fact that they are strangers, so they don't have to worry about being judged since they might likely not see the person again.