If this is true, it is only because we spent most of the last 10,000 years since the start of the Agricultural Revolution working under the assumption that if you need more food you need more land and the only way to get it is to go conquer your neighbor and take their land (and probably enslave them to grow your food for you too).
But that’s not practical anymore, because the last countries to do that on a large scale kicked off a World War and got their asses kicked. Now when we go to war it’s to topple your regime and replace it with one that’s friendly to us - which doesn’t solve our food situation.
The biggest reason for this is how Interconnected the world has become, and the kinds of goods that a country can produce that are now valued. In a Medieval world, if Mexico is at a disadvantage against America because the Iron mines of San Diego equip American legionaires with sharp swords and the wheat fields of Los Angeles feed a mighty army, Mexico can invade the US, seize the Iron mines and the wheat fields, put American captives to work, and bolster its economy.
In the modern day, most of the value of Los Angeles or San Diego comes from skilled labor. Manufacturing plants need raw material shipped in from elsewhere; tech companies need motivated programmers creatively solving problems and slavery isn’t very good at extracting that kind of labor; and financial institutions get all of their value from everyone agreeing that they have value, so if Mexican tanks roll in to Los Angeles financial firms would either flee (if their holdings are elsewhere) or lose all value. So conquering a modern city doesn’t really give you anything of value.
At the same time, if Mexico decided to invade San Diego and Los Angeles, the US - and all of its allies, friends, people afraid of pissing it off, etc - would stop trading with Mexico. Even if they managed to take those cities, for little benefit remember, this loss in trade would hurt them.
That doesn’t mean you can’t go to war nowadays, it just means that a war of conquest isn’t a very effective way to grow your nation. If you need a specific strategic location (Crimea) or if it’s a point of national pride (Taiwan) wars of conquest could very well be something we still see occasionally, but it isn’t a real solution to water scarcity or food shortages.
So does that mean we are doomed? I don’t think so. In the past, it was easier to seize more land rather than increase efficiency. The benefits of seizing land are down, and the cost of doing so is up; but the benefits of increased efficiency are up, and the cost keeps coming down.