On Enhancing Microgrid Control and the Optimal Design of a Modular Solid-State Transformer with Grid-Forming Inverter