That is also the case in my area of the US. The wooden structure must be a certain distance from the house, fence, etc. However smaller structure don't need a permit so people just ignore the rules if space is tight. And some areas don't have strict enforcement of the building code particularly rural areas. But those properties tend to have lots of space.