There are 3 methods that I know of.
1. in Terminal: sudo chflags hidden [drag file, folder or volume - use 'unhidden' for reverse]
2. if you have Xcode installed, you can use setfile application:
[drag setfile app] -a V [drag file, folder or volume to be hidden - use small case 'v' for reverse]
3. install supergetinfo. This one is easy, set the shortcut, use it on a folder or file and click on the 'invisible' box.
Sometimes I have to go through all 3 before one of them works, especially with volumes, so there are a few quirks and it pays off to have them all handy. Not really securely hidden, of course, but if one doesn't have a reason to search for hidden files, one will not search for hidden files. I use it mainly to hide volumes like time machine and other storage/backup discs away from my desktop.