Mexico President Andres Manuel Lopez Obrador told the United States on Tuesday that if it wants to stem the flow of Central American migrants to its southern border, it needs to invest in the region.
Slowing entries from Mexico has been a major focus of President Donald Trump's administration amid numerous reports of migrant caravans heading up from Guatemala, El Salvador and Honduras in the hope of a better life.
The migrants say they are fleeing poverty and gang violence, but Trump has characterized many as criminals and has ramped up pressure on Mexico to help ease the strain on US immigration authorities.
On Monday, Mexico detained 367 mostly Honduran undocumented migrants in its southern Chiapas state.
"We don't want to fight with the United States government, neither do we want to get involved in their partisan political confrontations," said Lopez Obrador.
"At the same time, with respect, we're asking that the problem be tackled with development, with the creation of employment, something that's not been done."
Trump has declared the issue a national emergency and demanded US legislators commit billions of dollars to building a border wall to keep migrants out.
Yet the numbers of Central Americans heading to the US is increasing.
Lopez Obrador said a plan announced last week to restrict migrants south of Mexico -- keeping them away from the US border -- was for their own safety and not a means to placate Washington.
"We don't want them to have free passage and not just for legal reasons but also for security," Lopez Obrador told his morning news conference.
"Unfortunately in the north we had problems with the murder of migrants at another time and we don't want this. Most of the violence is in northern states and we prefer looking after the Central American migrant population in the south and southeast."
In 2010, 72 migrants were kidnapped and murdered in the northeastern state of Tamaulipas while traveling clandestinely to the US.
They were believed to be the victims of the Los Zetas drug cartel that allegedly wanted to forcibly recruit them.