Wow. I actually agree with Elon Musk about something for once, what a shock!
Tom Scott has a very good video explaining why electronic voting is terrible all around and it will probably never be secure.
Tom Scott's video: https://www.youtube.com/watch?v=LkH2r-sNjQs Tom Scott's video via the Computerphile channel: https://www.youtube.com/watch?v=w3_0x6oaDmI&t=1s