Contrary to popular belief, Debt-to-Income DOES NOT affect your credit score. Your debt-to-income ratio is all your monthly debt payments divided by your gross monthly income. This metric is one way lenders measure your ability to manage the payments you make every month to repay the money you have borrowed. Lenders will use this ratio to see if you can afford a loan payment or to determine an appropriate credit limit on a credit card or line of credit.
If you rent with roommates but you are the primary leaseholder and we report the full rent amount to your credit report, this will not negatively impact your credit score. It could impact your Debt-to-Income ratio. However, assuming the roommate is on the lease and you can verify the roommate's payment, the lender would consider this roommate's rent as income which would correct your Debt-to-Income ratio.