The star stays where you left it -- unless it was stuck in the ceiling, in which case it may be below where you left it. When you die and respawn at a savepoint the strays are removed from the world and returned to you.
Some care has to be taken when throwing them to assure you'll be able to get them back without having to die first. They act predictably when they bounce off something, so you should always have a good idea of where they will end up.