Guillaume Gontard, sénateur