Yes, it is done all the time. Be careful with XX university admission dean though, they hate to see a paying student leave and will threaten you. All threats are without basis so don’t worry. Your best support will be the admission dean of yy university to enable the transfer.
Best wishes
Dr. Sandeep Shankar, email: hopehumanityATgmailDOTcom