When it's just continous rain or esp when it goes from hot to cold, I bring mine in. In storms though I would rather them be out. The barn is old and of tin and it's like a roar, when it's storming. You literally have to yell to talk. The horses all scream and kick the walls. They could get injured from flying debris I guess but they seem to have a strong survival instinct which maybe is why the barn in a storm is so scary to them. I wish they had an option of coming and going.
Unless I lock them in, mine that are in the barn all have the option of staying in their stalls or going out into their paddocks. I rarely lock anyone in unless it's a mare getting ready to foal or someone with a show the next day.