Azelf is not especially evasive. The difficulty is reaching him and surviving long enough to throw, so preparation matters more than luck.
A Master Ball ends the conversation instantly. Failing that, stock a good number of Ultra Balls before you head to Lake Valor, because running out means a long walk back.
Lower his HP as far as you safely can, then inflict sleep or paralysis. Status plus low health is what actually moves the catch rate, and Azelf's low HP floor makes a False Swipe user ideal.
Action Replay codes can generate unlimited balls, and they work. They also mark your save in ways that can matter for events and trading, and they remove the part of the game that is worth playing. Your call, but know the tradeoff.