Saute onion and garlic in olive oil in medium skillet till translucent. Add oregano, basil, marjoram, chili powder, and cumin and cook another minute, till fragrant. Add mashed yams (and beans, if using) and stir till well combined and heated through.
Lay tortillas out on work surface. Spread 1/2 cup filling on half of each tortilla, leaving a 1-cm border at the edge. Sprinkle each tortilla with 2 tablespoons cheese and fold over, pressing slightly to spread filling to edges. Place quesadillas on lightly oiled baking sheets. Brush tops with olive oil. Bake at 400 F for 15-20 minutes, till lightly browned.
Serve with salsa and sour cream if desired. Serves 8 as a main/side dish, 32 as an appetizer.