Matthew G. Whitaker, the chief of staff to Attorney General Jeff Sessions, would become the acting No. 2 official at the Justice Department, his White House counterpart, John F. Kelly, told him over the phone on Saturday morning, according to two people briefed on the call. To the White House, he was an obvious choice: a confident former college football player and United States attorney whom Mr. Kelly has privately described as the West Wing’s “eyes and ears” in a department the president has long considered at war with him.

By late Monday morning, the plan was moot. Mr. Rosenstein was no longer committed to resigning, at least without assurances he was doing so on amicable terms with the president. Mr. Trump told reporters on Wednesday that he was open to keeping Mr. Rosenstein in place, and two White House officials said they believed he was likely to remain in his job at least through the midterm elections.

But the arrangements to promote Mr. Whitaker show how White House aides seized on the days of uncertainty about Mr. Rosenstein to try to place a trusted loyalist at the top of a department whose traditional independence has long frustrated the president.