Wow....I am not sure there IS anything you can do about that. This looks extremely infected from possible bumblefoot or maybe even leg scale mites. I would imagine this bird is in terrible pain. I personally would put this bird down. The skin looks like it is rotting and turn gangrene like.
Not unless you know what you are doing. He will no doubt just bleed to death and suffer great pain. One of my quail recently ripped the tip of his toe off, a much smaller area of the toe and leg, and the bird nearly bled to death. I do not recommend amputation. But I do recommend putting the bird out if it's misery.