WASHINGTON — President Donald Trump’s explanation for why he fired FBI Director James Comey has shifted again.

Rudy Giuliani, Trump’s newest attorney, said in an interview on Fox News that Trump fired Comey last year because Comey would not state “that he wasn’t a target” of the special counsel’s Russia investigation.

He said Trump felt that he was treated worse than Hillary Clinton, who was publicly cleared of criminal wrongdoing at an unusual FBI headquarters news conference in July 2016.

“He fired Comey because Comey would not, among other things, say that he wasn’t a target of the investigation,” Giuliani said. “He’s entitled to that. Hillary Clinton got that.”

Comey told the Associated Press in an interview this week that he saw telling Trump privately — at a January 2017 Trump Tower meeting — that he wasn’t under investigation as a way to lower the “temperature” of an otherwise tense encounter before the president took office.

Giuliani’s explanation foreshadows a likely defense to the May 2017 dismissal, but it was just the latest in a series of rationales offered by Trump and his advisers.

It also comes as the president’s legal team is debating whether to allow Trump to be interviewed by special counsel Robert Mueller’s team, which in addition to investigating potential coordination between Russia and the Trump campaign, is examining whether the president’s firing of Comey and other actions constitute obstruction of justice.

“The president, frankly, doesn’t have to have a justification,” White House spokeswoman Sarah Huckabee Sanders told reporters Thursday. “He can hire and fire whoever he wants, and he made the decision to fire James Comey and that’s certainly a decision he stands by and one that he feels very justified in since.”

In announcing the firing, the White House initially cited the FBI director’s handling of the investigation into Clinton’s emails. Trump later told NBC’s Lester Holt he was thinking of “this Russia thing” when he made the move.

On Fox News on Wednesday night, Giuliani said Trump did the Holt interview “to explain to the American people the president was not the target of the investigation.”