Ab Initio Investigation of Atomistic Insights into the Nanoflake Formation of Transition-Metal Dichalcogenides: The Examples of MoS2, MoSe2, and MoTe2