If you say someone is “in bed” it means they are sleeping or resting in their bed or have not got out of their bed to start their day (e.g., “It’s time to get up. You can’t stay in bed all day!”).
We say “on the bed,” “on her bed” etc. to indicate the location of something placed above the bed covering (e.g., “I left your washing on your bed,” “Please don’t sit on my bed with your shoes on.”
Knowing whether in vs on vs at is correct often depends on the specific context.
QuillBot’s free Paraphraser can help you rewrite sentences to ensure you’re using prepositions correctly in your writing.