The reason dates back to the time of manual typewriters. When first invented, they had keys arranged in an alphabetical order, but people typed so fast that the mechanical character arms got tangled up. So the keys were randomly positioned to actually slow down typing and prevent key jams. The computer keyboard is a direct copy of the typewriter keyboard.

[1] It is so when they (typewriters) were first introduced they could easily be demonstrated to show how timesaving the device would be by having sales representatives quickly type out the word "typewriter" as all of these letters are found to be on the top row.

[2] Because typists have been trained on Qwerty keyboards since the 1860s and noone can be bothered retraining them.