Since the 1.17 update, certain buildings will no longer permit the placement of a fence kit inside of them that were possible in 1.16. There doesn't seem to be any consistency with the buildings, some low ceiling buildings work while others do not, floor material does not seem to matter either.
Some examples:
https://imgur.com/a/kEnrdHe
- Small clinic
- Christmas house
- Log cabins
- Barn house
- Small church
- Double red/green
Additionally some places where fences could once exist seem to be much more restrictive or being interfered with from nearby objects to a higher degree than in 1.16.
- Lamp posts
- Sidewalks
- Road signs