The "nations" that the US has imposed regime change upon, Iraq, Afghanistan, Libya, and others, aren't much in the way of nations. Once the US deposed the dictator, there was nothing to hold the place together. No law enforcement,. no courts, no legislature, no accepted code of law, no telephone system, little to no civil government. Without doing some, in fact quite a bit, of "nation building" the place goes to pieces. Warlords and terrorists take over, and the land becomes a breeding ground for crazies.
Afghanistan is a classic example. In the 1980's the Soviets invaded. A native resistance, the Mujahadin, took up arms against the Soviets and with substantial American assistance (plenty of Stinger back pack anti aircraft missiles) drove the Soviets out of the country. At which point, we Americans washed our hands of the place and went home. The Afghans were unable to create a national government and in an uncontrolled patch of Afghan ground, Osama bin Ladin set up shop and launched 9/11 on us.
Lesson that should be learned. Never allow wild lands without a responsible national government to emerge. Bad things like 9/11 come out of wild lands. We must do enough nation building to create a national government that can exert control over the national territory.
For instance, the US claims to be fighting against IS/ISIS/ISIL. Good idea. But, should we defeat IS/ISIS/ISIL what are we gonna do to set up and keep alive, a national government to maintain order in the land? Last time we pulled out and the place, which we had sort of stuck together, fell apart in a year after the Americans left.
If we are going to intervene in third world armpits, we need to be willing to do enough nation building to establish a regime that can control to place after we blow the current dictator away. If we ain't ready to shape the place up, we do better leaving the native dictator in charge.