In a small saucepan, combine the milk, sugar, egg yolk, and butter and heat on medium heat. Cook, stirring occasionally, until the mixture has thickened, for about 10 minutes. Remove from the heat and stir in the vanilla, coconut, and pecans. Put the mixture in the fridge to cool and thicken, for about 15-20 minutes.