President Trump moved closer to revising the North American Free Trade Agreement by striking a deal with Mexico, but cast new doubts over the quarter-century-old pact by threatening to leave out Canada.

While the deal was created to foster harmonized rules across the continent, Mr. Trump said on Monday he was happy to sever Washington’s northern...