After obtaining the Triforce, you must go through the Gate of Time to reach the final boss.
After going through the Gate of Time to the Sealed Grounds of the past, go outside to the area where the Imprisoned was in the present time. A cut scene will take place, and then you have to fight your way through many monsters to reach the bottom of the pit.
First Wave: Red Bokoblins and Five Helmeted Bokoblins
A large number of red bokoblins will attack. You can simply run past them until Ghirahim creates a fence in the way, or kill them as you go along. Be sure to pick up recovery hearts to stay at full health if possible. These bokoblins won't block you with their swords, so they are easy to get rid of.
Once you're blocked at the fence, five helmeted red bokoblins will appear. You have to kill them to remove the fence. They will block with their swords.
Second Wave: Bomb Bokoblins and Three Wooden Shield Moblins
Don't hit the bomb bokoblins with your sword or you will get hurt in the explosion. Just run away from them to let them blow themselves up.
At the next fence, Ghirahim will summon three wooden shield moblins. Kill any bokoblins that are still running around, then focus on the moblins. You can use bombs to get rid of their shields quickly, or just run up the shields and attack them from behind.
Third Wave: Archer Bokoblins and a Blue Bokoblin
There will be bow and arrow bokoblins along with a bunch of red bokoblins attacking you. There will also be more bomb bokoblins. The archers are grouped together, so a spin attack should allow you to quickly get rid of all of them at once.
The blue bokoblin that appears at the fence can do a charge attack at you with its sword. It also runs away sometimes, so deal with any red bokoblins that are still attacking you until the blue one gets close enough to attack again.
Fourth Wave: Horn Bokoblins and Two Stalfos
After getting rid of the blue bokoblin, the wall will go down and you will have to deal with some bokoblins that carry horns. They use these to summon more bokoblins. The song that they play is the flute kid's song from Link to the Past. Kill the horn bokoblins as quickly as possible, and then pick up its horn when it dies. Otherwise, another bokoblin will pick up the horn and use it to summon more monsters.
At the final wall, two stalfos will appear. Kill them the way that you have before, then run down.
Final Wave: Everything
After killing the two stalfos, you will have to get past monsters of all types. Luckily, you can just run past them. There is no need to kill them this time. Run down to the very bottom of the pit and Ghirahim will create a wall behind you.
Ghirahim will create a wall around himself and Zelda, and will summon a bunch of red bokoblins. Kill them all to proceed to the next part of the game.