so rebase is kind of a weird concept to understand, it is very easy to understand when drawn out though.
say you're head is currently at revision A. your remote repo is currently at A. your buddy is currently at A.
your buddy then makes a change locally to his repo and is now at B. he makes another change and is now locally at C.
your buddy then pushes his changes to the remote branch. so now you have ...
you are at A, remote is at C, and your buddy is at C.
now you make a change to your local branch and commit it locally. now you are at D.
so now if you go to push your changes, it will not let you, because you are behind the remote branch. this is when you will want to do a 'git pull rebase'.
what this will do (in one command that will either succeed or fail), is pull your current repo to C, and it will then attempt to commit your changes on top of C. so you are basically rewriting history (locally) at this point. if there are no conflicts, it will then put your change D (locally) on top of C. if there are conflicts you will manually have to resolve them before you can continue with the pull/rebase process. there will be messages in the command line if you have issues and it tells you how to resolve them.
after it succeeds, your local repo will have changed from A->D, to A->B->C->D.
and since the remote branch is A->B->C you can now push your change cleanly to the remote repo, which will then have A->B->C->D afterwards.
so does that make sense? it took me quite a while to understand rebasing and i didn't fully "get" it until my coworker drew it on a whiteboard for me. merging is a different beast, but merging is actually very easy with the rebase and merge commands. you literally just rebase your branch with the base-branch, and then merge that back into the base-branch and it will be a smooth process (other than resolving conflicts with the rebase). i like to use the no-ff flag when merging branches because you can see a very fine line of where the branch was merged in when looking at the history in the log.
this example is also only with 2 people and very few commits. but in the real world, you can have a lot more commits when doing these rebase processes. in that example, say you committed E, F, G, H, I, J, K after D. all of those commits will then be rebased on top of B and C in that example, and if your buddy had committed a lot more commits, well you can see why there is a chance of more conflicts and things that need to be resolved.
at work i've had branches out for over a month that i constantly rebase with develop, and by the end of the feature being finished, i have like 60 commits that have to be rebased with develop. usually it's pretty smooth though since i rebase frequently (every day or so) so there won't be many conflicts typically.