NATO declared that Ukraine could be part of the alliance 6 months before the invasion and Russia immediately started their troop build up.
You could argue that NATO is a defensive Alliance but much of the world does not view it that way. The US uses NATO bases for every war it conducts and houses nuclear and non-nuclear missiles and in NATO countries.
Independent of whether you think NATO is a defensive Alliance, this statement condemns the expansion of alliances even for the purpose of increasing security of the Allied countries. It states it quite plainly that it opposes defensive alliances too