Laws about rape typically are concerned with the notion of consent.
Children are not competent to make many decisions, and one of those decisions is the decision to consent. Children do not have the right to say 'no' to sex with an adult - they are not competent to make the decision at all. They choices are made by their guardians and by society.
Because children cannot consent to sex, an act of sex with a child is rape.