So if deal between Apple and Ireland was illegal, shouldn't Ireland be fined as well?
Why? Not fining Ireland serves a very useful purpose: it means any country can easily agree to these schemes, and then back out painlessly. Apple pays all the costs of crony capitalism (presumably they have to spend time and money placating politicians), and receives none of the benefits. Attempting to fine the Irish government would just make it harder to punish Apple, since presumably the Irish would also fight any penalties directed at them.