My left foot has been swollen for about 2 months. My doctor X-ray itt, no problem. Some pain but not too bad. I am not diabetic. What could it be?

Get more studies. You could possibly have a stress fracture that may not show up on an xray. Other explanations include possible mild arthritis, nerve injury, inflammation of a joint or tendon. The location of your pain may guide your physician in determining the problem. Nevertheless, an MRI can be helpful to diagnose your problem. Please see an orthopedist.
Get it diagnosed. Some causes of pain and swelling of foot can include systemic problems such as hypertension, gout, and problems with the kidneys and localized issues such as arthritis, infection, lymphatic obstruction, blood clots, varicose veins, trauma (fracture, sprain, and tendonitis) and side effects to medication. Have it evaluated by a professional and get the appropriate treatment.
Stress fracture, . Stress fx, ligament injury less likely infection if not diabetic and no wound. Would recommend repeat x-ray or MRI for full evaluation.