I just did a quick google search as I was curious to learn more myself and found this interesting Cook Islands government site outlining the history of the Cook Islands.
Cook Islands Government Online
From what I can tell, they are basically independent now. It also appears I was wrong about the defence. New Zealand obviously assists militarily, but ultimately they are resposible for their own defence. My best guess (and it is just a guess) is that even though they are effectively independent, the fact that the people of the Cook Islands are New Zealand citizens puts them into a sort of grey area with respect to groups such as the UN.
Would allowing the Cook Islands to become official members of the UN effectively give New Zealand two votes? (sounds like a good idea to me

)
Is it possible to be a separate nation in the UN if all of it's people are citizens of another nation already in the UN? - I just don't know
There is an interesting excerpt on that site regarding the free association which I think sums up the unusual relationship quite nicely.
"The special relationship between the Cook Islands and New Zealand is on both sides a voluntary arrangement which depends on shared interests and shared sympathies. In particular it calls for understanding on New Zealand's part of the Cook Islands' natural desire to lead a life of their own and for equal understanding on the Cook Islands' part of New Zealand's determination to safeguard the values on which its citizenship is based."