You have to do it through Paypal or the other payment gateway that the customer used.
Paypal
https://www.paypal.com/us/smarthelp/article/i-want-a-refund.-how-do-refunds-work--faq3248
Stripe
https://help.pixieset.com/hc/en-us/articles/115003008251-How-do-I-refund-my-client-via-Stripe-
For others ... Google it.