Hello
Is there any way to run a filter manually? It suppose to go through the existing messages in the inbox and move the ones matching the criteria. The filter seems to work on new messages but not on old ones.

Correct, the sieve rules apply only when a new e-mail arrives.
There's however a (Dovecot) HowTo, if you must run the rules manually: http://wiki.dovecot.org/HowTo/RefilterMail
But I've never done this, so I can't tell if it'll work.