Thermal paste is a medium. That's all. Even something mirror polished still has microfine scratches, pits, craters irregularities that are too small for you to manually see. Application of 2 such surfaces, that being the cooler and the cpu lid just makes those irregularities exponentially higher as now you get huge air gaps where valleys sit on top of valleys. Those surfaces simply are not perfect. Thermal pastes fill the gaps and allow physical transmission of the heat through, instead of trying to pass that heat through air.
You can use any liquid based medium as a thermal paste, as long as it's some sort of conductor not a insulator. That means even toothpaste is viable, denture cream, coconut oil etc.
The problem with those compounds is they dry up, dissipate, evaporate, cook and change composition under the extremes of heat generated by a cpu. You are used to cpus being @ under 100°C, most ppl are. A cpu without a cooler can hit 250°C in seconds, more than enough to cause serious damage. Without something as a medium to transfer equally all that heat, everything not 100% covered is going to be a Hotspot and the cores underneath will suffer 250°C + in those minute spots. Considering the @5.5 Billion transistors at 14nm size under a Haswell lid, minute is actually pretty large.
So yeah, coconut oil will work. Temporarily. Anything from seconds to minutes to unknown. Depends on how long it takes to drip down into the cpu pins and short out the socket or dry up and crack, cooking the cpu, or shrink and leave open areas, cooking the cpu.
Your choice, but paste is paste for a reason, and tooth paste, or denture paste or hair conditioner isn't the same.