The five U.S. attorneys along the border with Mexico, including three appointed by President Trump, recoiled in May 2018 against an order to prosecute all illegal immigrants even if it meant separating children from their parents. They told top Justice Department officials they were “deeply concerned” about the children’s welfare.

But the attorney general at the time, Jeff Sessions, made it clear what Mr. Trump wanted on a conference call later that afternoon, according to a two-year inquiry by the Justice Department’s inspector general into Mr. Trump’s “zero tolerance” family separation policy.

“We need to take away children,” Mr. Sessions told the prosecutors, according to participants’ notes. One added in shorthand: “If care about kids, don’t bring them in. Won’t give amnesty to people with kids.”

Rod J. Rosenstein, then the deputy attorney general, went even further in a second call about a week later, telling the five prosecutors that it did not matter how young the children were. He said that government lawyers should not have refused to prosecute two cases simply because the children were barely more than infants.