afaik there's no direct way to increase stats using abilities.
you can, however, make an ability based on Item Hero Stat Bonus, then set the attribute bonus to whatever you want, and a dummy ability that the unit casts. then when the unit casts the spell, make a trigger that adds the stat ability to the unit.