First you would have your normal bike and go to a BMX track. You start going on the track and try not to go too fast, and wear shin pads, long sleeves, long trousers, a helmet and gloves.
When you get to the point of your Mum and Dad saying "We're going to get you a BMX bike" you should ask someone to have a go on their bike so you know whether it's the right one for you. Mine is a GT Junior and was quite expensive. It cost £160.
When you get back to the track, you have a few practice goes as fast as you can go. Then have a rest and a bit of food and water and ask someone if they will race you (and make sure they are your age).
Then you might be able to go racing, which is quite popular. Don't be like me, when I was in the best lane (lane 1) but had a bad start and finished last. There is a start gate which stops anyone from starting too early.