There have been multiple threads on multiple forums about this.
Stuffing that cord back in the hole is always going to be a problem. Access the cord where it connects inside, cut it leaving enough to reach a twist-lock inlet, put a plug on the end and not have to worry about it. The result will be like the photo below.
Actually mine looks different now because I added a second 30A service, but yo get the idea.