Something to keep in mind with prescribed exercises is, if it hurts, don’t do it. Pain is a signal that you are doing something your knee isn’t ready for. Working through pain will keep your knee inflamed, creating more pain and swelling. Your new knee needs gentle treatment so it can heal. Too many of us are subjected to too many painful exercises. They are not necessary.
Mobility is important, short walks and very gentle knee bends will take care of that.