The sounds you are hearing are called crepitus. Crepitus is related to slightly uneven cartilage surfaces in the affected joints (ankles and knees in your case) rubbing on each other when you move the joints back and forth. Crepitus is often a sign of aging joints and arthritis
but it can also occur in relatively young people without these problems.
The main thing is to determine if you have any pain when moving the joints when this occurs or if there is any stiffness or resistance to movement of the affected joints. Other concerning symptoms would including a sudden feeling that the joint "gives way" or any weakness or instability when walking or exercising. If you experience any of these symptoms, then you should talk to your primary care doctor
, who can perform a physical examination to determine if there is any evidence of arthritis or another joint condition.
In the absence of any concerning symptoms, however, you should not be overly concerned by the noise, other than to take the usual precautions to exercise carefully, wear sensible supportive shoes, and avoid injury
through wearing appropriate protective equipment for sports and other physical activities.
If you have any further questions, feel free to discuss them with your primary care doctor.