Combine cornstarch and water in a small bowl. Stir until cornstarch is dissolved then set aside.
In a medium-sized saucepan over medium heat, combine coconut milk and sugar. Whisk constantly until mixture begins to simmer.
While continuing to whisk, SLOWLY pour in the water/cornstarch mixture until it thickens. Reduce heat to low and continue to whisk until you have a thick, pudding-like consistency. This is important, it needs to be thickened while it is heating or it won't set up.
Pour into a greased 8"x8" baking dish or square containers. I actually like to use my smaller glass Tupperware containers becasue the sides are more straight, making for more consistent squares.
Allow to cool to room temperature, about 10-15 minutes, then cover and refrigerate for 2+ hours.
When ready to serve, cut into 2" squares and serve cold. If serving as a custard or pudding, pour into individual serving ramekins or bowls and chill.