The nation’s largest brokerage and its biggest mortgage lender are joining forces to fix the ailing housing market.