Deformations of Courant pairs and Poisson algebras