Groups and monoids of Pythagorean triples connected to conics