When you're about to edit a payment you may notice that the payment is in a locked deposit. When you go to the deposit there may not be a link that you can click to unlock the deposit.
If you don't see a link to unlock the deposit this could be because the deposit has already been posted. On the deposit record look at the post status. If it says posted that means the deposit has been posted to the general ledger and can no longer be unlocked or edited.