Federer suffered a stunning US Open fourth round straight-sets upset at the hands of Spanish 19th seed Tommy Robredo on Monday.
It is the first year since 2002 that the 32-year-old has not made a Grand Slam final and sparked feverish speculation over his future in the sport with the loss to Robredo coming on the heels of a second-round exit at Wimbledon.
"Roger did not play close to his maximum level so it's always a question of why is he not playing well. People need to give him a break a little bit, because I think it's normal to expect that he's not moving as well as he did when he was No. 1 and he was so dominant," said the Serb.
"For me, he's still playing really well and definitely deserves to be one of the top five players in the world, no question about it."
Djokovic said he would not be advising Federer on what his future plans should be despite his rival having slipped to seven in the world, his lowest ranking for over a decade.
"How long he's going to play? That's a question for him. But he's what, 31, 32 years old? Tommy Haas is 35 and close to the top 10.
"So I think people are seeing Roger always being a top three, top two guy and competing for Grand Slam titles. That's not happening, and all of a sudden it's a huge surprise."
World number three Andy Murray, the defending champion, said he was surprised to see Robredo beat Federer for the first time in 11 meetings.
But he believes a series of wins could restore Federer's place in the elite.
"I think a lot of players go through periods where they're not playing their best tennis, and that has obviously been the case with Roger since around probably Wimbledon time," said Murray who, like Djokovic, is safely into the quarter-finals.
"He had a few issues with his back this year as well. He's still hitting the ball well. He still has the same strokes. It's just when you lose a few matches you are supposed to win, then you lose a little bit of confidence.
"That's huge in this game."