There's quite a difference between a moral wrong and a legal wrong.
The theory of tax works like this..... A party such as a state or an actor who can exercise the writ of their law becomes competent to collect taxes.
Once upon a time it was kings, churches, mafias and persons who could coerce others to give them a portion of their earnings which would collect taxes for their own private uses. This of course was all non-productive accumulation and quite pointless and led to various wars and revolutions.. such as in France and Russia etc.
Later taxation became part of social contract, particularly as the kings, churches and mafias were threatened by the rise of communism and the collective bargaining power of the taxed population. The tax collectors decided to use some of the revenue collected to re-invest in the public that paid it. That's what the NHS and the growth of the citizen orientated state through the post-war period was all about.
This situation slowly disintegrated and today we live in a World with no viable public collectives or Russian communists etc. Simultaneously the State is withering away and multinational powerful corporations are becoming the main economic players with coercive abilities. Corporations in a sense collect taxation from the public through legalised "unjust enrichments" perhaps akin to tributes and have enough bargaining power to avoid paying taxes to any governments.. such as the recent Starbucks case showed.
In the same fashion governments can only exercise coercive power against citizens rather than corporations and claim revenues for the sustenance of the state. Notably since the state cannot act against corporations in favour of its citizens the state becomes redundant. (Think of the mafia don who cannot protect his patch from other mafias encroaching).
Since the citizens and public are not prepared to form collective bargaining bodies or interest groups anymore (because of ideological perversions and illiteracy) and there is no threat of Russian Communism etc. States do not feel the need to re-invest any proportion of revenues collected into the citizenry and rely on raw coercive power and propagating falsehoods and obscurantisms only.
Additionally States suffer from regulatory capture in as much as corporations and in most cases just crudely act in their favour.... (UK v EU on Bankers' bonuses)... This tends to happen because the extent of capture is so huge that the competence to coerce the citizen into pay taxes is given as a prebend by the corporations to the most preferential persons supposedly representing the State such as can be seen in the UK in particular.
Tax avoidance thus becomes a more sensible and rational option for the citizens and the public.
Anti-avoidance propaganda being promulgated these days by governments amongst the public are actually utter nonsense considering that corporations and the various rent-seeking and political beneficiaries of the captured state (Republicans, Conservatives etc.) hardly pay any tax at all themselves and control the vast majority of wealth, land and capital.
The very suggestion of any taxes in its entirety becomes totally unconscionable if not only immoral.
More realistically.... is that in countries like the UK rather than tax, the state/king/beneficiaries that own all the means of a country's production.....distribute the profits amongst the citizens. This happens to some extent in some rentier economies like Saudi Arabia and the UAE and some socialist states. The advantage here is that taxation need not be avoided as it is either minimal or non-existent.