Thanks for the clarification.
It seems to me that it's possible to model the evaporation and condensing effects at two ends of a heat pipe, using blocks from the two-phase (2P) domain. It may not be easy though.
Couple blocks that I think may be useful for you:
Receiver Accumulator (2P) https://www.mathworks.com/help/releases/R2020a/physmod/hydro/ref/receiveraccumulator2p.html This one will allow you to model the two ends of the heat pipe. I suggest this instead of a simple chamber, because you need a way to allow only the liquid phase to travel away from the cold end through wicking, and gas phase away from the hot end (by pressure?). This block gives you the option to do that. The thermal port will allow you to heat or cool the fluids.
What I am not sure or clear about is how to model the wicking of liquid from the cold end to the hot end. Any correlation you are aware of for the capilliary effect that's driving the flow? You'll need to find a way to implement that on the liquid path. The vapor path, I think, will be driven by the pressure difference because the hot end will have a higher vapor pressure.
Your model could conceptually look like this:
Hope this helps.