During the harsh reality of the siege, a false hope took hold among the residents of Jerusalem. Many people were fully prepared to endure the severe pain of starvation and disease inside the city walls. They believed that simply holding their ground and refusing to leave would somehow save their home, sparing them from having to surrender to the enemy.
The prophetic warning arrives specifically to shatter this illusion. It makes it completely clear that the city will inevitably fall to the army of the Babylonian king, regardless of what the people do. Because the capture of Jerusalem is an absolute certainty, enduring such extreme suffering and attempting to defend the city is entirely pointless [מלבי״ם].