Feat implement rotate functionality

**Summary:**
* `rotate` option implemented (it can be used along with other operations, actual rotation will happen last).
* process flow changed & small refactorings.
* tests.