Victoria Azarenka has won the Sony Ericsson Open for the second time, beating Maria Sharapova in the final.