So I've started trying to go for our walk after homework is done. This works better when homework actually gets done in less than 3 hours....
Your reason to do homework first makes sense. It may be too high a goal to have ALL the homework finished before going on a walk. What about setting a goal to spend one hour on the most important homework and then a walk (or Lego break), followed by another hour if needed? 3 hours seems like a lot.
I'd put a positive spin on his interests as they're great opportunities to develop attention to detail and effort (cooking, Legos, music, animals). Maybe pointing out his strengths in these areas will help.