Optimum design for microgrids that include renewable energy sources (RESs) is a complex process that requires optimization across a wide range of factors, including economic, technological, and environmental effectiveness. The inverter-connected RES units lack the rotational mass required to maintain the system’s inertia and can result in significant frequency instability during disturbances. The battery energy storage system-based virtual synchronous generator (BESS-VSG) is a unique approach to address this challenge since it mimics a conventional synchronous generator (SG) using the inverter regulation concept. Furthermore, given the recent rise in electric vehicles (EVs), EV owners’ charging patterns impact the microgrid’s operational, financial, and technological aspects. Therefore, this research offers a novel Modified Multi-objective Salp Swarm Optimization Algorithm (MMOSSA)-based technique for optimal photovoltaic (PV), wind turbine (WT), BESS-VSG, and EV charging station (EVCS) allocation on microgrids. The objective function is designed to optimize the total net present cost (TNPC), levelized cost of electricity (LCOE), energy loss, frequency deviation, voltage stability indicator (VSI), and carbon emissions. The proposed strategy is evaluated on two real-world grid networks: Masirah Island in Oman and Ankara in Turkey, where wind prospects, solar potential, and EV charging patterns are conflicting. This study investigated PV/BESS-VSG, WT/BESS-VSG, and PV/WT/BESS-VSG configurations regarding the weather and load variability for the two test networks. The obtained results demonstrate that the PV/WT/BESS-VSG is the best choice for both the test networks, with TNPC values of 261030.9 $ and 303840.5 $, respectively, and LCOE values of 0.0383 $/kWh and 0.0469 $/kWh, respectively. The carbon emissions are reduced by 88.8% and 87.3% for the two test networks, respectively. In addition, with the accurate PV/WT/VSG design and appropriate EVCS placements, the microgrids’ renewable fraction, the quantity of sold energy, and technical characteristics improved significantly. Moreover, employing numerical analysis, different loss of power supply probability (LPSP) values, spacing index, and hyper-volume index, the suggested MMOSSA method is compared to five relevant multi-objective optimization strategies. The findings demonstrate that the MMOSSA Pareto fronts offer better solutions across all the assessments.