My daughters phone won’t charge, unless you push the cable right by the socket. I’m gonna replace her screen, she broke it quite early on but has managed to use it anyway, and thought I would replace the USB socket at the same time. But I can’t find it in the shop. Is it attached to something else?
Please have a look at this (not very encouraging) threads. Maybe it is just the cable … but it sounds like the connector on the board of the phone is broken. You need to find someone who can solder it onto the main board for you with the right tools.
Maybe you can find someone in your area for this. Sometimes young people setup “fix shops” or “hacker spaces” that have these kind of tools. Else you need to buy a new main board … or a new or used phone