Both regular pillagers and pillager captains can continuously spawn around the structure. Pillagers can still spawn if a player is inside the tower. In Java Edition, they spawn in a 72×54×72 area centered on the top level of the watchtower, the same level as the chest.
It's like witches, wither skellies, etc. The structure is just an indicator of an invisible box in which those special mobs spawn. This is how peóple make farms of them.