Sprained ankle 1.5 mos ago, rested and feeling better but now pain when I wake up in the morning, why is that?

Pain. In morning is most common in the heel area. You don't mention if its in the same area of the ankle injury. If its in the ankle it could be scar tissue from tight ligaments after injury. Try stretches and if continues see your doctor.
Many possibilities. If the pain returned in the ankle itself, your pain may be related to a thickened tissue formed in the lining of the ankle in response to the injury or cartilage damage sustained in the initial injury. If the pain is along the inside arch or bottom of the foot you may be experiencing plantar fasciitis. You should seek orthopedic evaluation to confirm the diagnosis and treatment.
Ankle sprain. If the pain is in the same location or other areas around the same ankle, get it checked out by your treating physician. If the pain is on the bottom of your foot, you may have another ailment called plantar fasciitis. If its inside ankle, you may have a defect in your ankle bone. If that doctor isn't available, find one in your network that specializes in ankle sprains.