It’s not really possible to do this easily. The "prototype" (what Factorio calls objects) can only be modified at launch, not in real-time.
However, you could build everything with regular electric poles first, and then use the upgrade planner to switch them to underground ones. I believe that’s the quickest way to handle this issue.