Specifically, the scene you're likely thinking of is in "Harry Potter and the Order of the Phoenix", where Harry faces a disciplinary hearing for using magic outside of school. This hearing takes place within the Ministry of Magic, more specifically in a large, impressive courtroom.