WASHINGTON — White House officials insisted on Thursday that Judge Neil M. Gorsuch, President Trump’s Supreme Court nominee, was not referring to Mr. Trump’s recent denigration of judges when he said privately that he was disheartened by attacks on the courts.

Mr. Trump said on Twitter that the nominee’s remarks had been misrepresented, a sentiment echoed by the White House press secretary, Sean Spicer, during a contentious briefing. A day before, members of the White House team guiding Judge Gorsuch’s confirmation verified that the judge had expressed his dismay in response to questions about Mr. Trump’s insults of judges.

The administration’s abrupt shift highlighted the degree to which Judge Gorsuch’s nomination — a top priority for the president and his core supporters — has become mired in a broader debate over Mr. Trump’s attitude about the constitutional principle of judicial independence.

The Run-Up

The podcast that makes sense of the most delirious stretch of the 2016 campaign.

The president’s feud with the judiciary — he referred to the district court judge who blocked his targeted travel ban as a “so-called judge” and called an appeals court hearing “a disgrace” — is dominating the Senate’s consideration of Judge Gorsuch’s nomination. Senators from both parties are demanding that the judge answer for the president who named him.

Mr. Spicer said that when Judge Gorsuch told senators that he considered such criticism “demoralizing” and “disheartening,” he was referring broadly to any such attacks on the judiciary.

“The judge was very clear that he was not commenting on any specific matter, and that he was asked about his general philosophy,” Mr. Spicer told reporters during a series of testy exchanges. “So you can’t then take that and equate it back to the specific. He literally went out of his way to say I’m not commenting on a specific instance.”

On Thursday, former Senator Kelly Ayotte, Republican of New Hampshire, who is helping with the confirmation process, issued a statement in which she said of Judge Gorsuch, “While he made clear he was not referring to any specific case, he said that he finds any criticism of a judge’s integrity and independence disheartening and demoralizing.”

Mr. Trump lashed out on Twitter at Senator Richard Blumenthal of Connecticut, who first revealed Judge Gorsuch’s remarks after meeting with the nominee on Wednesday. The president noted that Mr. Blumenthal had lied about his service in the Vietnam War and suggested that he had also misstated his exchange with the judge.

The White House’s statements upended what had appeared to be a carefully calculated effort by Judge Gorsuch to gently distance himself from Mr. Trump’s attacks — what some observers saw as an attempt to blunt Democrats’ concerns about whether the judge would stand up to what they call Mr. Trump’s overreach.

While Judge Gorsuch may be working to allay those concerns — under the current Senate rules, he needs some Democratic support to be confirmed — Mr. Trump’s Twitter post and Mr. Spicer’s denials confirmed the worst suspicions of Democrats who were already bent on transforming the process into a referendum on the president.

Senator Chuck Schumer, Democrat of New York and the minority leader, said he had called on Judge Gorsuch in their private meeting on Tuesday to publicly condemn Mr. Trump’s comments about judges.

“He said, ‘Well, I’m disheartened by it,’” Mr. Schumer said. “I said, ‘Your feelings aren’t enough here.’ It’s really not good enough whispering behind closed doors that you’re disheartened. I didn’t think it came close to being enough.”

Senator Ben Sasse, Republican of Nebraska, said he, too, had questioned Judge Gorsuch about the president’s attacks, particularly his reference to a “so-called judge.” Mr. Trump has also called the courts “so political” and said that the judges weighing his travel ban had questioned legal principles that even “a bad high school student would understand.”

Mr. Sasse said on the Senate floor that Judge Gorsuch “got a little bit emotional, and he said that any attack or any criticism of his brothers and sisters of the robe is an attack or a criticism on everybody wearing the robe as a judge.”

“I think that’s something that this body should be pretty excited to hear someone say who’s been nominated to the high court,” he added. “He said that it is incredibly disheartening to hear things that might undermine the credibility and the independence of the judiciary.”

Interactive Feature | Get the Morning Briefing by Email What you need to know to start your day, delivered to your inbox Monday through Friday.

Mr. Trump’s allies suggested that Democrats were seeking to use Judge Gorsuch as a political pawn in their battle with the president over the executive order on immigration, which could well end up before the Supreme Court.

“It puts the judge in a very difficult spot,” said Leonard Leo, a top adviser to Mr. Trump on the Supreme Court process. Judge Gorsuch, he added, is “trying to be gracious, he’s trying to be forthright, he’s trying to be responsive to questions that senators have, and they’re pushing upon him a set of issues that are overtly political and that he, as a matter of judicial ethics, really can’t venture into. I think he did the best he could under the circumstances.”

Veterans of the Supreme Court confirmation process note that the ritual of private meetings with senators is almost completely staged for minimum controversy and maximum impact, with questions discussed in advance, answers honed and rehearsed, and no remark made unless it is intended to withstand public scrutiny.

“You don’t want any surprises, so there’s nothing that you don’t prepare for going into a meeting,” said Stephanie Cutter, a top Obama administration official who shepherded the nomination of Justice Sonia Sotomayor. “They knew this question would be coming, and they would have practiced an answer, and this was what he planned to say.”

Ms. Cutter recalled preparing Justice Sotomayor for a meeting with Senator Patrick J. Leahy, Democrat of Vermont, then the chairman of the Judiciary Committee, in which she worked to explain her remarks that that a “wise Latina woman” could reach a “better” decision than a white man. Mr. Leahy left the meeting and promptly repeated the explanation to the assembled reporters, an effort to dispense with the issue before she came before the Senate for confirmation hearings.

“This might have been an attempt to make him look more independent,” Ms. Cutter said of Judge Gorsuch. “He could have created a story line about standing up to Trump.”

But the denials on Thursday were at odds with that narrative. Democrats were quick to jump on them as proof that Judge Gorsuch lacked judicial independence.

“We take Sean Spicer at his word that Judge Gorsuch did not mean to distance himself from Donald Trump’s attacks on the judicial branch,” Zac Petkanas, a senior adviser for the Democratic National Committee, said in a statement. Mr. Petkanas called it proof that the nominee “will be nothing more than a rubber stamp for this out-of-control Trump presidency.”