Free indirect discourse lets a character's thoughts and idiom flow through the narration itself. It keeps the grammatical third person and past tense of the narrator but adopts the vocabulary, rhythm, and judgments of the character — so the line belongs to both at once.
It's the engine of much great close-third fiction, from Austen to Woolf, because it gives the immersion of first person while keeping third person's flexibility. It pairs closely with deep POV.
Tagged: 'She thought the party was a disaster.' Free indirect: 'The party was a disaster. Whose idea had the punch been?' — the second sentence is clearly her voice, not the narrator's.