Your math seems right, and an expertise in those skills would explain that difference.
However, PCs and anything else do not follow the same rules. Monsters, creatures, NPCs, etc. can all have different stats than a player character would have without having the additional features a player character would need to get those stats.
As for why an Aboleth would have expertise in history...
Aboleths, according to the Monster Manual, are older than the gods, and an aboleth remembers with perfect clarity everything it has ever experienced. Additionally, aboleths pass their memories down to their offspring, including their own parents' and ancestors' memories. So, every aboleth remembers perfectly everything it ever experienced, everything its parent had experienced up to when it was born, everything the parent aboleth's parent had experienced before the first one's parent was born, and so on, all the way back to the very first aboleth, who was old enough to remember a time before the gods existed!
I'd be surprised if they didn't have expertise in history after all that!
Incidentally, this also happens to be the reason every aboleth utterly hates and despises the gods, because every aboleth remembers, in perfect detail, when the gods overthrew their rule!
As per the Monster Manual, page 14...
Before the coming of the gods, aboleths lurked in primordial oceans and underground lakes. They reached out with their minds and seized control of the burgeoning life-forms of the mortal realm, making those creatures their slaves. Their dominance made them like gods. Then the true gods appeared, smashing the aboleths' empire and freeing their slaves. Aboleths have never forgotten.
Aboleths have flawless memories. They pass on their knowledge and experience from generation to generation. Thus, the injury of their defeat by the gods remains perfectly preserved in their minds.
Aboleths' minds are treasure troves of ancient lore, recalling moments from prehistory with perfect clarity. They plot patiently and intricately across eons. Few creatures can conceive of the extent of an aboleth's plan.