I think the main reason has not been mentioned: bolts with Allen heads use less space than bolts with hexagonal heads, an advantage which gets even more pronounced when considering that hexagonal machine bolts require additional space for an outside socket (or even more for a wrench). The maximal transferable torque is only an advantage argument when comparing screwdriver slotted heads or Philips heads, not for hexagonal machine bolt heads since transferable torque values are similar to bolts with Allan heads.
Saturnhr