You want to keep the player's
relative position within the rectangle to remain the same after rotation of the rectangle?
Before rotation, convert the player's position to the rectangle's space:
sf::Vector2f convertedPlayerPosition{ rectangle.getInverseTransform().transformPoint(playerPosition) };
Then, transform your rectangle how you want (rotate the tiles).
Then transform the converted player position using the rectangle's transform:
sf::Vector2f newPlayerPosition{ rectangle.getTransform().transformPoint(convertedPlayerPosition) };
Don't forget to rotate the player too.