Islam considers sexual relations an essential human need which need not be suppressed, rather satisfied in a proper manner. It is not something looked down upon disdainfully, nor something from which a person should refrain.
Islam has set certain laws by which an individual can both control and satisfy this need. One is not to satisfy this need in an animalistic or lustful, uncontrolled manner. The only legal channel through which this desire should be satisfied is marriage. The ultimate goal of marriage in Islam is to achieve psychological and emotional stability for both spouses. Allah says:
They are clothing for you and you are clothing for them (2:187)
monumental commentary of the Qur'an, he notes:
“[commentators from among the Companions of the Prophet and their students] said that this verse means, ‘Your wives are a resort for you and you for them.’ ArRabi` bin Anas said, ‘They are your cover and you are their cover.’ In short, the wife and the husband are intimate and have sexual intercourse with each other….”
Islam safeguards the individual and society by forbidding everything which can excite the sexual desire for fear that a person would commit fornication or rape.
This of course would result in the proliferation of illegitimate children who have no parents to raise them morally. They would then emerge in society as a group who harbor animosity and hate towards others. Also, diseases would spread throughout society.
Allah says: And do not approach unlawful sexual intercourse. Indeed, it is ever an immorality and is evil as a way. (17:32)