You can soak it, but don't have to. Basically, the wood will leech tanins into the water which are not harmful, and some people say are good for the fish. It will also lower your Ph a little. but most importantly it will turn your tank water brown and make it look like cold tea!!! That is why soaking is recommended.
A lot of people like this brown water look, but that is personal taste.
If the wood was bought from a fish shop then you'll probably be ok without boiling it, but it's worth doing anyway just to make sure there are no nasties in it. then soak it for as long as it takes for the water to be clear!!