They are based on a fallacy: "I am irrationally afraid and persecuting this innocent person will make me feel better."
Which is expressed by those in power as: "There's a good reason I'm afraid and punishing this person will make that reason go away."
Hunting witches never makes things better. Partly because there are no witches.
But mostly because it's really unlikely that we're afraid for a good reason (our fear is just about always irrational). And of course, our irrational fear has nothing to do with the person or the group we're using a scapegoat.
So much more useful and productive to say, "I'm afraid," and leave it at that.