part of the difficulty here is misapprehension of what this charging is. We're sort of preconditioned to think of charging as charging for effect- like a bull, or someone trying to tackle. In those cases, the person charging is at full speed or still accelerating at the moment of contact. That's not really what's going on here. What this is falls more into the category of marching attack- putting tempo pressure on you in order to force the timing of striking distance. A marching attack is effective because the attacker can slow, speed up, or change direction in order to adjust the timing of the engagement. The main goal of the defender is to spoil this control.
1. Continuous retreat. This is instinctively tempting, but disastrous. When retreating against a marching attack, the typical reaction is to retreat at or near the speed the attacker is coming forward. This turns the situation effectively into two fighters standing their ground or slowly coming together, except that one person is defending. The fighter with the longer reach has several advantages in this situation.
2. Stand your ground. This leaves all the control to the attacker, and so the defender has to entirely rely on being able to read the attack. Marching attacks also usually involves lots of feints- the attacker wiggles the weapon and can variously speed up and slow down to feint commitment. Makes it difficult to read and solve passively.
3. Waiting then sidestep/rolling/lateral movement. This instinct comes from that initial misapprehension. If the other person were really charging, this would be a good option. They are not. Their actual intention is to come to a stop right in front of you. They're already decelerating hard at the moment when you would sidestep. Foam weapons have a minimal weight commitment. There is some advantage in causing retargeting by sidestepping, but it's about the same as for a normal engagement.
4. Advance one step as the attacker is coming into range. The advantage here is that at the critical moment things accelerate for the attacker. They have to launch an attack sooner than expected. If you have previous knowledge of their favorite/instinctive swing, that's probably what they will fire. Still, this is happening when they are likely paying the most attention to you, so depending on your timing/telegraphing, it will not be that surprising.
5. Retreat one or two steps, fast, as the attacker is about to swing. Done properly, this making their attack fall short or causes them to lengthen/slow/re-evaluate. In general, makes it easier to deal with.
6. Feign continuous retreat, sudden stop. This starts to return some control to the defender. Moving backwards continuously makes the attacker comfortable and gives them some commitment. Stopping gives the advantages of option 4, with the additional advantage of being able to choose the moment. The biggest mistake with this one is when people think this is what they're doing, but in reality they're just retreating and stopping when they realize they can't get away, which is just about the worst thing to do.
7. Instant forward movement at the start of their charge. Sort of like a counter-charge. Has to be done from very large distance, or it becomes a weaker version of 4, where the attacker has more time to adjust. Instead, what you're hoping for is the attacker to slow or abandon the charge, expecting a typical defensive engagement. You can then either give them this, or stop/retreat and make them start their charge again. Stopping and starting is tiring for them, and thus good for you. If they continue and you continue at speed that's going to turn into an uncontrollable situation. Not my thing but if you're outclassed or into chaos it might work.
8. 7, stop, then engage. The goal being they start to charge, slow/stop when they you're coming to them, then they start accelerating again thinking you're not, and then you're there while they're still getting up to speed. Tricky, but you get all the goodness of an opponent coming towards you while not actually prepared.
best, of course, is a combination of all of the above, with the general goal being to cause stutters, hesitation, exhaustion, and regain control.