re: "I end contract and payment is pending"
That's fine. When you end a contract or who ends a contract has no impact on the freelancer getting paid for all of the time that she logged.
If a FREELANCER closes a contract AFTER work has been released, but while money is stil in the "pending" box, then that is fine. The money is still going to go to the freelancer. If a freelancer ends a contract before the money has been relased to the freelancer (the money is still in the "Work in progress" stage), then the escrow money goes back to the client.
re: "If I end the contract can the client still send feedback to me?"
If you end the contract, the client is notified that you have done so, and the client is asked to leave feedback. The client has a 14-day window during which they may leave feedback.
The client may choose to not leave feedback at all. Or the client may no longer be paying attention to messages from Upwork, and may never notice the invitation to leave feedback.