It seems many objects (fences, buildings, antennas, etc.) in the vicinity of an airport are painted in a red and white checkerboard pattern. Notably, the pattern is not of the same scale on different objects: a fence or shed will have red/white squares a couple of feet across, and larger objects tend to have larger squares.
So…why the red-and-white pattern, and why differing length scales?
The simple answer is that red-and-white paint is required by the regulations for a structure greater than 300 feet high. I’m guessing that different sizes are because different structures lend themselves to different sizes.
If you really want to know “Why is it prescribed that way?”, then white is the best colour to be seen at night, as it reflects most (even yellow swallows some amount; and reflectors are a relativly recent invention and also more expensive for big things like sheds compared to two buckets of paint)
and red is the best colour to be seen in a fog or snow storm, where white just disappears. So combining those two colours makes sure your shed or whatever can be seen under all weather.
Regulating it to checkers just means that it’s easier for pilots to recognize than having to deal with different patterns.