That question means the nurse, assistant, or physician perceives you as two things:
1. Female, and
2. Young enough to potentially be pregnant.
Many treatments, especially medications, must be modified or adjusted to keep your fetus safe, so if you are potentially pregnant, they need to know. That's why they ask.