What is the purpose of heating agar powder
An agar gel sets as it cools, like almost every other thermoreversible gel - including those made from gelatin, carrageenan, and various types of gellan and pectin.

One of the properties of almost any gel is that the gelling agent needs to be dispersed and then dissolved in the solution, otherwise you'd never be able to mix it - you'd just instantly get a solid lump as soon as you tried to mix it in. The particles need to be very small and the molecules fairly far apart from each other in order to work their magic.

Most substances dissolve more easily at higher temperatures. You've probably seen this with sugar if you've ever tried to make a candy or syrup. You can saturate cold water and up with... well, sugar-water, but to get a syrup (or hard candy) you need it to be supersaturated - i.e. to have a higher concentration at some temperature than would normally be possible by just mixing at that temperature.

Here is a more detailed explanation. It's due to the second law of thermodynamics, and it's a little hard to explain in simple terms; but basically, higher concentration implies lower entropy at some given temperature, and you cannot lower the entropy of an isolated system. It needs to be able to transfer that entropy to another system, and in this case it does so by dissipating heat (and to dissipate heat, it must be given heat). It's really not the best explanation - if anyone with a stronger physics/chemistry background can summarize it better in one paragraph, feel free to make an edit.

Anyway, hydrocolloids like agar and gelatin have exactly the same issue. They'll disperse in cold water, but won't dissolve. To dissolve them, you need to heat the solution first. Agar just happens to be the most dramatic because it won't dissolve at all until you reach temperatures of about 90° C. Technically you don't actually need to boil it, but it's easier to just boil than it is to try to hold it slightly below boiling. Precision isn't necessary, as long as it's at or above the dissolution (AKA hydration) temperature.

Only once these agents are properly dissolved will they exhibit any gel-forming properties. So, you need to heat them past the dissolution temperature first.