Heat a large skillet over medium heat, melt butter in the hot skillet, and stir chayotes, sugar, garlic, red pepper flakes, and ginger into butter. Cook, stirring frequently, until chayotes are tender, about 15 minutes; season with salt and black pepper.