In his new book, Wimbledon: My Life and Career at the All England Club, Becker wrote that Federer and Djokovic "don't really like each other" and Federer "cannot possibly be as nice as he seems."
"I find such comments unnecessary," Federer said in an interview with Berner Zeitung. "He cannot know whether I have a problem with Novak. It's true at the beginning I didn't like his [behavior] on the court but today he behaves wonderfully and is extremely fair.
"We don't spend a lot of time together. Our best friends are other people. But when we meet we are relaxed and talk as normal."
The 17-time Grand Slam champion also disputed that his image is put on.
"Becker has no clue," Federer said. "He should actually know me well enough to know that I'm a relaxed guy. I'm friendly and polite to people, with no need to change my behavior. Sure, sometimes I have to collect myself when I'm tired or in a bad mood, but that's part of the job."
Federer indicated that the comments caught his attention because they came from a player he admired when he was younger. "I didn't like hearing what he told," Federer said. "He was one of my idols. But I also don't know exactly what he said, especially since on Twitter he [contradicted] half of it."
Becker's book excerpts were quoted by the Daily Telegraph. The six-time Grand Slam champion has since said on Twitter that he was "misquoted" in various media stories and has the "utmost respect" for Federer.
Federer has frequently listed Stefan Edberg (his coach), and Becker (Djokovic's coach) as the players who inspired him growing up.