Desert village Villagers who spawn inside of the buildings are spawning one block above the ground (or most likely just on the stairs) which results in their heads being stuck inside of the roof blocks.
They obviously can't move because of that.
Very common issue that can be seen in almost every desert village.
EDIT:
The seed when there's a few villagers stuck like this is 55555555
Coordinates of the village and houses: -1247 68 2080 and -1239 68 2071 (villagers stuck in two nearby buildings)
There's two more on the other side of that village if I remember correctly.
Another seed, same issue with two villagers (I destroyed part of the wall so both villagers can be seen):
Seed: 167761456
Coordinates: 292 70 -3427
- duplicates
-
MC-146770 Villagers and mobs are spawned in floating and offset in villages upon world generation, occasionally getting stuck and suffocating
- Open