It varies from one Taekwondo organisation to another, and there generally isn’t a formal list of requirements as there is for lower levels of black belt.
At lower levels of black belt – generally from about first degree black belt to sixth degree black belt – there are formal requirements for what a student must do in order to be awarded that degree. This generally includes having trained for at least a certain amount of time since your last grading, and having trained regularly. It may also include having participated in a number of competitions – either as a competitor or a referee – and it may include having completed special training sessions for black belt students.
Again, the specific requirements for being awarded lower levels of black belt vary from one organisation to another.
For higher levels of black belt – seventh, eighth, and ninth degree black belt – whether a person is or is not awarded such a degree is often at the discretion of a committee of high-ranking Taekwondo practitioners (other seventh to ninth degree black belts). The committee will take many things into consideration, including how many competitions that person has helped to organise, how long they’ve been teaching Taekwondo, how many students they’ve trained to black belt, how many courses they’ve run, and more.
The committee will look at what that person has contributed to Taekwondo overall – including what books they may have written on Taekwondo. They will also look at whether that person embodies the tenets of Taekwondo.
Becoming a grandmaster in Taekwondo takes a long time – an optimistic estimate shows that it takes at least thirty years if you progress as fast as possible (have a look at this post for more information).