To get the Mandrake, you need to:
1. Complete the first two Herbology lessons. This will unlock the greenhouse area.
2. Find the Mandrake seed. It is located in a pot near the back of the greenhouse.
3. Plant the seed and water it. The Mandrake will grow over time.
4. Use the Mandrake's scream to stun the Basilisk. This is the main purpose of the Mandrake in the game.
Remember that the Mandrake's scream is deadly to humans, so you need to wear earmuffs to protect yourself.