Tunnels and “mouseholes” in walls also allow for undetected movement between buildings. Hamas fighters expect they can emerge from these holes to attack Israeli soldiers before disappearing again.
In addition, Hamas sappers have likely prepared many improvised explosive devices (IEDs) – some hidden in walls to detonate when armoured vehicles pass by and other, larger explosives buried under roads. Some tunnels may also be set as traps to entice Israeli soldiers to enter as they search for hostages.
Source: The Conversation