Former world number one Maria Sharapova has won her first title since May 2015, beating Aryna Sabalenka 7-5 7-6 (10-8) in the Tianjin Open final.