In the movie Harry Potter and the Order of the Phoenix the last scene is Dumbledore talking to harry in his office at hogwarts so how at the start of Harry Potter six are they at the atrium?

Because, of course, for this movie, they back trcked to that part for storu continuity reasons. Movies do this allot, show a scene that was already seen so you can keep up with the emotion and thought process of your characters.