Yes, some operating systems are more secure than others. Some, such as OpenBSD, make a real point of protecting you from attackers. Others, such as Windows, have had a bad reputation, but have gotten better over the years. Still others, such as Linux and Mac OS X are known for being secure, but in Mac OS X’s case, at least one major security flaw, the SSL goto bug, has seriously damaged its reputation.
When all is said and done, however, the real security problems in the 20-teens, according to security firms FireEye and Secunia, are not in our operating systems but in the applications we run on them.