Randomizing crowd scenes with instanced models
My hammer is python, and your problem looks like a nail.  I would develop python that can instantiate copies of the bodies and hairpieces at the proper locations (http://web.purplefrog.com/~thoth/blender/python-cookbook/link-mesh-array.html illustrates the basics of this technique).

Linking meshes with armatures is done with modifiers like in http://web.purplefrog.com/~thoth/blender/python-cookbook/bone-orientation-demo.html (which also includes examples of adjusting the orientation of bones).

A python solution to your problem is somewhat involved, but I am optimistic that there are examples of all the techniques you need somewhere on stackexchange or google.