You need your tank to cycle and stabilize first. You're likely to encounter undesirable forms of algae (e.g. green, brown, cyanobacteria etc) during this period of cycling and just after.
Thereafter, you can limit undesirable forms of algae by adhering to the following:
Purifying your source water (preferably RO/DI). Having pure/clean source water should prevent excess nutrients and phosphates from getting into your tank.
Don't over feed and perform regular water changes.
Test for phosphate and utilize phosphate removal media if necessary.
Promote coralline algae growth (stable PH, Calcium, water parameters).
Keep good water parameters generally (i.e. 0 ammonia, 0-low nitrate, 0 nitrite etc)