To temporary save your changes use
git stash
To retrieve them again after switching back use
git stash pop
You can also apply the changes but keep the changes in your stash like follows:
git stash apply
With this command you could apply your changes on multiple branches.