As mentioned, in most of the U.S., summer is harder on cattle than winter. Cattle are big heat producers, and have difficulty dissipating heat.
Many build sheds or barns for shade. Only problem is, without flow-through ventilation, it can be hot in there. So trees, or an open sided shed make for better shade than a barn. And if dirt bottom, that retains heat more than grass out in the field.
For winter, just a 3 sided shed will suffice to allow them to not lay in the snow and protect from wind. They can do okay without it, but in bad cold, they'll need more feed to stay warm if they're laying in the snow, vs in bedding under a shed. Then of course, cleaning is an issue.
Sometimes better to be out in a clean, cold field, than in a dirty shed or barn.
Which reminds me, many think that in humans, colds are caused by cold weather. Research shows no direct correlation with ambient temperature. Instead, in cold weather, people come indoors more, and the spread of virus increases with crowding. So if moms really don't want their kids to catch a cold, they should kick them outside in the cold, instead of staying inside slobbering all over each other.