"And he lay with Bilhah his father's concubine" (Genesis 35:22). Heaven forbid that he touched her. Rather, when Rachel died, Jacob took his bed and set it down before the couch of Bilhah. Reuben came and was zealous for his mother's honor, and because Jacob did not set his bed before Leah his mother, he disturbed her bed. Therefore Scripture accounted it to him as though he had lain with her. This is what is written, "And he lay" and so forth. And even so, Scripture made him equal with his brothers, as it is said, "And the sons of Jacob were twelve" (Genesis 35:22). [This teaches that all of them were of equal weight as one.] And it called him firstborn, for he is the firstborn with regard to conception, the firstborn with regard to inheritance, the firstborn with regard to service, and the firstborn with regard to repentance.
Reuben Disturbs Bilhah's Bed and Remains Firstborn
Midrash Aggadah, Genesis 35:22
וישכב את בלהה פילגש אביו. חס ושלום שנגע בה, אלא כשמתה רחל נטל יעקב מטתו ושם אותה לפני ערש בלהה, בא ראובן וקנא לאמו, ובשביל שלא שם מטתו לפני לאה אמו בלבל מטתה, [לפיכך] העלה הכתוב כאלו שכבה, הדא הוא דכתיב וישכב וגו', ואף על פי כן השווהו הכתוב עם אחיו, שנא' ויהיו בני יעקב שנים עשר. [מלמד שכולם שקולים כאחד] וקראו בכור שהוא בכור לעיבור, בכור לנחלה, בכור לעבודה, בכור לתשובה: