As president, Donald Trump is in charge of the FBI. Which makes it incredibly striking that, in a Thursday morning tweet, Trump accused the bureau of having conspired to spread false intelligence about him during the 2016 election:

Workers of firm involved with the discredited and Fake Dossier take the 5th. Who paid for it, Russia, the FBI or the Dems (or all)? — Donald J. Trump (@realDonaldTrump) October 19, 2017

The reference to “Fake Dossier” is to the infamous Steele dossier, a list of allegations about the Trump campaign’s links to Russia put together last summer by retired British spy Christopher Steele. It’s the source of many of the most extreme claims about Trump, including that he paid prostitutes to pee on a bed in a Moscow hotel room that President Barack Obama had previously slept in during a visit to Russia.

Trump is wrong about the dossier in two different ways. First, we know who paid for it and it wasn’t the FBI: private American political donors, first supporters of Trump’s Republican primary opponents and later Democrats trying to torpedo his general election bid. Second, while he’s right that the dossier is not fully confirmed — particularly some of the most salacious details such as the urine incident — but by no stretch of the imagination is it “fake.” In fact, a number of its claims have been found to be true.

“Well before any public knowledge of these events, the [Steele dossier] identified multiple elements of the Russian operation including a cyber campaign, leaked documents related to Hillary Clinton, and meetings with Paul Manafort and other Trump affiliates to reportedly discuss the receipt of stolen documents,” John Sipher, a 30-year veteran of the CIA, writes in Slate.

But Trump’s public attacks on the FBI are perhaps even more worrying than his lies about the dossier.

The FBI is supposed to be a quasi-independent check on the White House. It’s the agency tasked with investigating wrongdoing by the executive branch. While presidents can fire bureau directors, they are not supposed to do that except under extreme circumstances, and they’re certainly not supposed to do so as punishment for looking too closely at the president’s fishy behavior.

This is what made Trump’s firing of then-FBI Director James Comey back in May, which he admitted was a response to Comey’s refusal to back off the Russia investigation, so troubling. The fact that Trump is continuing to publicly feud with the FBI — which is still investigating his ties to Russia at the direction of special counsel Robert Mueller — suggests the president believes any attempt by the bureau to hold him accountable for his past actions is corrupt and needs to be stopped.

There are heads of state who act this way. But they aren’t usually in charge of democracies — at least, not for very long.