Alexander Zverev beat Denis Shapovalov 6-7(5) 6-3 7-6(4) in the ATP Cup group stage to give Germany a 2-1 win over Canada.