Any cable can work. But if I use a cheap "2.1A" charger from eBay (at least also with a cheap cable), I will often get a "Slow charge" warning from the phone, telling me it will charge faster if I use the stock charger. I'm not sure how it tests/evaluates the charger & cable, but it has the ability to decide that some setups are not very good.
I have found (anecdotally) that I get better results using an old LG 0.7A charger for an old phone, vs using my eBay "2.1A" chargers. And the LG 0.7A will often charge at right around 0.7A, while the "2.1A" chargers seem to make the phone warmer, and charge at lower currents. I don't know which is the cause of the problem, admittedly, since the phone heating up will make it reduce the charge current.
But you're better off to use a decent USB charger, vs a cheap generic charger, despite the specs it may claim. I bought an Aukey QC 2.0 charger for $10 off Amazon, I've been very happy with it, and it charges faster than the LG (about 1900mA vs 1600mA). Now I try to use it or the LG charger & cable, vs my cheap ones. I get better results that way.