You can, but the flavors and texture will not be the same. Palm sugar has a lighter taste and texture than coconut sugar. Both are sweeteners, but coconut sugar is not used in Thai cuisine.