I am an oncology nurse and I have been a surgical patient too, so I can answer this question from either perspective. However, I think personal experience is a powerful means to articulate the best answer.
I had a brain tumor that affected the cranial nerve responsible for balance and it completely made me deaf in one ear. So rehab was essential for my ability to walk, navigate the hearing world, and regain strength. The exercises entailed balance and strength training. No rehab was offered for the hearing loss, but through researching I learned the best way to deal with unilateral hearing loss.
As a nurse, I can tell you without any doubt that good rehab will result in better physical outcomes. Muscles, tendons, fascia are all damaged during surgery and must be carefully trained back into the best shape possible. For example, I dealt with breast cancer patients who had mastectomies. This surgery can entail the removal of lymph nodes and muscle. The patients would go into rehab to stretch and strengthen the shoulder and relax chest wall muscles to prevent the muscles/joint from freezing in place.
For many surgeries, the physicians will have the patients up and out of bed as quickly as possible and into rehab soon after. The reason for getting out of bed is to encourage the lungs to work properly, prevent pulmonary infections, prevent blood clots, and encourage full body strength and mobility.
It's sometimes hard to get patients up, get them moving, and get them into rehab. Surgery hurts. Sometimes a lot. The human instinct is to prevent movement if in pain. So having a great rehab team is essential for the surgeon to see the best surgical outcomes.
I hope this is useful!