Is that Pokemon the only one with that hm in your soul silver game.
If it is then it won't let you transfer it, kind of like how the Pokemon comes back if you try to release the only Pokemon with that hm.
The reason this happens is because if you transfer the only Pokemon that has surf for example, then you could be stuck on an island if you don't have a fishing rod or any other Pokemon that can learn surf.
Source:Experience
Hope this helped.