Once that's taken care of and the leg is shorter, they can plug the foot back in ~ probably by putting in a steel prosthetic device giving him his previous leg length and pulling sinews, muscles and blood vessels down to meet the foot.
It sounds remarkably like that technique the Russians worked out to STRETCH LEGS for very short people.
My daughter had that procedure to stretch her smaller leg at the Shriners hospital when she was 9. It is called the Illizerov method named for the Russian doctor who developed it. She would have had one leg 4 inches shorter than the other as an adult. They broke the lower leg stabilized it and we screwed it apart a very small amount every day. The bone filled in and now her leg is the same size as the other. She was on painkillers but we got her off afterwards. Then they put blocks in the growth plates of her other leg during her growth spurt a few years later to make up the rest of the difference.
We are forever grateful to the Shriners.