When replacing coils it's a good idea to replace the spark plugs as well, and the two (short) HT leads if they didn't come with the coils.
Mine's a 1.5 and has had 3 coils, yes both on one occasion and an odd one when the garage broke it taking it off too quick
I guess yours may be new enough to be a 1.6? The CEL had only just been introduced then (mine doesn't have one) and the on-board diagnostics are not as accurate as they should be. By which I mean it can give the wrong code.
From experience I can report that if you put it into a Mazda dealer they will replace the MAF sensor and charge you £250 (in the UK) and that may not fix the problem either!