Hello, Greetings of the day!
Any form of s*xual relationship between two minors, irrespective of their consent is called as statutory rape, which is unlawful or illegal because either parties of such act is below the legal age to get involved s*xually, further making them incapable of giving their consent to the said act. Hence, the consent is irrelevant.
Statutory rape comes under the purview of Section 375 and 376 of Indian Penal Code.
Hope it helps