Yes if you can get the nails out cleanly and you can get screws with outer diameter wider than the nails were. My dad did this on his deck because the builder he hired failed to use galvanized nails and they started to rust immediately. Unfortunately the builder also nailed the nails in at an angle so it caused the screws to not lay flat. Still better than it was.
BTW, my deck is 29 years old and some of the nails are gradually working up, but the lumber is still good. I'll first try to hammer them back down, but if they don't stay, I'll try to replace with screws.