Barr denied in an interview with CBS News that he made a bid from the president, who had repeatedly paralyzed the probe, to carry out the remarkable reversal.
"No, I command the law," Barr said.
The filing drew swift criticism from former top FBI officials who had worked on the case and supported the investigation of Flynn, whose lie about his contacts with Russia prompted Trump to fire him three years ago and Special Counsel Robert Mueller for turning him over to cooperate in the Russia investigation.
Barr reiterated the legal reasoning to close the case filed in the filing Thursday, which argued that the lie that Flynn was being accused of telling investigators was in fact not "material" or influential for an investigation.
"A crime cannot be committed here. They had no basis for an investigation against Flynn at the time," Barr said, referring to the FBI.
"People sometimes ask for things that turn out not to be crimes," he added.
Barr said he expects criticism from people who see the move as political, adding that he thought it was "sad that today these partisan sentiments are so strong that people have lost some sense of justice."
Barr was also asked how he thought history would look back on dropping Flynn's case as an indication of Barr's decision making.
"Well, the story is written by the winner," Barr replied. "So it largely depends on who writes the story."
Justice Department spokeswoman Kerri Kupec said Thursday that the department did not inform the White House of its decision to seek to dismiss the Flynn case.
After suggesting last month that Flynn would be dispensed with, referring to FBI agents as "dirty, dirty cops," Trump said Thursday that Flynn is "innocent."
"I'm very happy for General Flynn," Trump added. "He was a great warrior and he is still a great warrior, now in my book is an even bigger warrior."
In the interview, Barr further criticized the FBI's handling of his interview with Flynn and the charges stemming from it, saying that the agency had set a "perjury trap" by opening a dormant antitrust investigation by Flynn that allowed investigators to sit down with former security adviser.
"The whole exercise was just about creating the lie," Barr told CBS News.
Barr called the decision to try to close the case "simple" when he saw the evidence presented by the U.S. attorney who had reviewed the case, highlighting former FBI Director James Comey's move to circumvent his boss at the Justice Department when he sat down up the interview with Flynn.
Barr also told CBS News that he thinks Flynn's conversation with then-Russian ambassador Sergey Kislyak was appropriate and even "commendable."
He defended current FBI director Christopher Wray, who has come under criticism from the president's allies and in certain conservative media circles following recent disclosures in the Flynn case.
"He has been a great partner to me in our efforts to restore the American people's confidence in both the Department of Justice and the FBI, and we work very well together," Barr said. "And I think we both know that we need to step up – that it is very important to restore the confidence of the American people."
Barr said the FBI's handling of the Flynn case is still under investigation as part of U.S. Attorney John Durham's probe of Russia's investigation, calling former officials' decisions at that time "part of a series of related actions."
Barr said Durham will "probably" write a report, adding that "we are watching" any violations of the law that could lead to criminal charges.
Barr also plans to ask Jeff Jensen – the US attorney Barr appointed to review the handling of the Flynn case, which said Thursday that he recommended the case be closed – to "do some more work on different things as well," he added.
CNN's Katelyn Polantz contributed to this report.