Shame develops when we misinterpret events, words, or actions that were done towards us (but were out of our control). Instead of realizing the truth (often because we are to young and don’t have the life knowledge or skills) to see the situation correctly, we mistakenly think it is our fault and we are to blame.
The problem is that most of us were not taught as children how to deal with shame. So we internalize it. Think it is us. Believe the lies that shame whispers about it being our fault and that we deserved it. And as adults continue to believe these same lies.
Go deeper, read How the Lies of Shame Cause Us to Think We Are the Defective Ones, post 3.