Peel, seed, and dice the papaya into small cubes.
In a large saucepan, combine the sugar and water.
Add the cinnamon stick, cloves, and ground nutmeg (if using).
Bring to a boil over medium heat, stirring occasionally until the sugar is completely dissolved.
Reduce the heat to low and add the diced papaya to the syrup.
Stir gently to coat the papaya with the syrup.
Cook the papaya in the syrup for about 30-40 minutes, or until the fruit is tender and the syrup has thickened to a jam-like consistency.
Stir occasionally to prevent sticking and burning.
Stir in the lemon juice just before removing the pot from the heat.
Allow the Doce de Papaya to cool to room temperature.
Transfer to sterilized jars or containers and refrigerate.
Enjoy your meal!