Thanks for using the forum. I am happy to address your questions, and my answer will be based on the information you provided here. Please make sure you recognize that this forum is for educational purposes only, and it does not substitute for a formal office visit with your doctor.
Without the ability to examine you and obtain a history, I can not tell you what the exact cause of your symptoms is. However I will try to provide you with some useful information.
Just lack of sleep of it's own should not cause a swelling of the foot. Feet can swell up if say you keep standing for a long time, or even sitting , because fluid pools with gravity and if there is not enough movement, the foot or ankle can swell up. But lack of sleep per se should not have that effect. Depending on if you have pain with it or not, swelling can be because of arthiritis, joint infection, inflammation around the tendons of the ankle or rarely due to a undiagnosed fracture ( especially if you have a history of foot injury or trauma). Swelling of both ankles can be seen in venous insufficiency ( the veins are not doing their job to take the blood back up from the legs, hence resulting in pooling of blood and swelling), heart problems or kidney problems resulting in excessive fluid in the body.
Associated features with your ankle swelling would help one narrow down the possible causes.
I hope this helps.
Good Luck!