don’t modify dict keys while iterating through them

in jsonutil.rekey
test rekey modify-in-place
Merge pull request #6081 from minrk/rekey-inplace

don’t modify dict keys while iterating through them