The easiest way is with an area annotation over the heat map. (Pictured below). Simply right click on the heat map, choose Annotate and then Area. Then format to add the border, color and weight.
Unfortunately this will only allow you to create a square or rectangle area. Anything else (as in your example), if possible, would be significantly more complex.
If this response is helpful or answers your question, please mark it as such so that others can find it quickly.
Tableau Online Deployment Advisor