Sure it's fine to use DB instead of BB. In fact, you might find them more stimulating to your target muscle. My caveat to you though is to take great care in handling them. Personally, the risk of injury from getting into and out of position with DBs heavy enough for 5 rep training outweighs its benefits. Listen to what others advise. Also, when you get to a level in your training that you can lift some heavy DBs, the dumbells get so big that the range of motion in pressing is not that much greater than a straight bar because the dumbells clank together on top.
As you can see, for these reasons I prefer the barbell for pressing. (You can always hit the hammer strength for a little while if DBs are too much of a hassle to train with and you're burned out on barbells).