Chinese company BYD has become the world's bestselling electric vehicle maker, taking over from US rival Tesla.