I have a lot of opinions on the issue, so I'll try to keep it brief.
In the wild, cockatoos (and other animals) have predators, disease, intra-species disputes, famine and pests. They are not spending their time flying around, leaping through rainbows and revelling in their freedom. They have a very high and specific set of things that cause them stress.
However, having said that, cockatoos have had millions of years of evolution to equip them with the tools to deal with these stresses. The reason birds don't drop dead of fright whenever they see an eagle, is because they have evolved with the eagle as part of their environment.
They are stressed, but they are able to deal with this stress, to a point.
In captivity, there are usually no predators, pests, disease, etc. Or if there is, it is dealt with.
However, there is a whole new set of stresses to deal with, stresses the parrot has not evolved to deal with.
Loneliness, boredom, confinement. These are not things a parrot has evolved to deal with. It does not have the neural history to comprehend such things.
A young parrot, raised in captivity, will cope with these unnatural stresses much more than a wild-caught parrot or an aviary-raised parrot, but it will still suffer in these circumstances.
Luckily for us, as good parrot-keepers, we understand this, and try to prevent our parrots from experiencing these stresses. We give them company, toys, play-time, etc in order to protect our parrot from these unnaural stresses.
So yes, some may consider it unethical to keep parrots in confinement. However, if the parrot is cared for well, I see nothing morally wrong at all.
(I didn't keep it brief...)