Phase transitions in quantum models of rotators and ferroelectrics