Thank you for posting here in the Community. It would be my pleasure to answer any question you may have with correcting an invoice and payment in QuickBooks Online.
Can share with me what specific changes you need to make on the transactions? Is it some minor details from the header or the amounts?
You can edit the invoice and payment through the Transaction List section if it's still hanging on the Undeposited Funds account. Please disregard the message prompt saying that the transaction is already linked to others while performing the changes,
Here are the steps:
For your visual reference, here's a sample screenshot of the warning message:
In case the payment is already deposited into your bank register, I recommend following the steps in the article I recommend:
If you need further assistance from me regarding your sales transactions, please let me know. Any additional information or screenshots will ensure timely solution on this.