It varies state by state. In some states what you describe is legal, in others it is not.
The age of consent in most states is 16, but some places is as high as 18. Some places have a close-in-age exception.
The penalties vary state by state, but could include several years in prison (though that's unlikely in your scenario).
Anyway, without knowing what state you're talking about, we can't give more specifics.