In the Bible, there was no particular motivation behind Seth’s conception. Adam and Eve simply copulated after Abel’s death and counted their new child as a gift from God. But Midrashic literature, a genre of interpretive rabbinical texts, framed his birth as a fulfillment and reinforcement of the injunction to “be fruitful and multiply.”
The story goes that Lamech, a descendant of Cain, took two wives. Genesis 4 described how Lamech killed two men and warned his wives that as Cain would be avenged seven times, he, Lamech, would be avenged seventy-seven. The Midrash identifies one of the slain as Cain himself, whom the blind Lamech killed in an accident. Because any children the women had by Lamech would be of the seventh generation from Cain, they refused to lie with him and bring forth any children who would be cursed.
At Lamech’s request, Adam came to his wives and chastised them. “Who are you to preoccupy yourselves with the ways of the Lord? He does what He must do, and as for you, do your duty as wives!” he told them, very much reflecting a more ancient time and attitude. The wives snapped back that, since the death of Abel, Adam and Eve have not slept together nor had any more children. Unable to argue, Adam and Eve came together and had Seth.