Coconuts are the favorite gift for both Haley and Linus, and it's needed to complete the Exotic Foraging Bundle in the Crafts Room in the Community Center. It's also used for the Tom Kha Soup recipe, so it's a nice item to have.
Like other Foraged Fruits, it can be looted directly from the ground, and you will find it scattered on the ground in the Calico Desert. It will spawn in any season, so just go to the desert to find some. They will gradually respawn after having been looted by the player, and the supply is therefore rather limited since they can't be farmed like many other items.