What I have heard is only some, not all, have this trait. This is a recessive trait that is to help protect the herd. If a wolf or something attacks the few who have this will become paralyzed so the others can get away.
That type of goat has that freezing mechanic embedded in their genes. Its like how American possums play dead when a perceived threat comes close to them. I think these quirks that pop up in animals are interesting.
Unfortunately, this species was bred by humans to be like this. It shows how humans can change the genetics of animals, yet can't figure out how to fix problems today....
but that's a topic for another day.