The proliferation of distributed energy resources (DERs) imposes new challenges to distribution system operation, e.g., power quality issues. To overcome these challenges and enhance system operation, it is critical to effectively utilize all available resources and accurately characterize unbalanced distribution networks in operational tools. This paper proposes a convex second-order-cone programming (SOCP)-based AC optimal power flow (ACOPF) model for three-phase unbalanced distribution networks, including smart inverters and Volt-VAr controller (VVC) devices. Reactive power-voltage (Q-V) characteristics of smart inverters of solar photovoltaic (PV) units are also modeled. Moreover, the settings of Q-V characteristics of VVC are co-optimized within the proposed ACOPF, considering the allowable range of the IEEE 1547-2018 standard. Furthermore, dynamic analyses are conducted to verify the stability of optimal settings of VVC. The proposed models are tested on an actual 1747-node primary distribution feeder in Arizona. The results illustrate the effectiveness of the proposed ACOPF for unbalanced systems in providing an optimal solution while capturing the non-linearity and non-convexity of ACOPF. By co-optimizing settings, system operation is improved due to the flexibility of adjusting reactive power output from PV units with VVC. The time-domain simulations show that the optimal settings cause no stability issue for the distribution system.