Investigation on Atomic Structure and Mechanical Property of Na- and Mg-Montmorillonite under High Pressure by First-Principles Calculations