One would not usually describe a submarine as 'floating', particularly if submerged. It could be termed to be "at sea", to be "underway" (or "under way"), or to be "making way". A couple of other suitable terms are available, depending on the situation.
More-or-less-technical terms (British English, recognised by mariners internationally due to their use in the International CollRegs, not specific to submarines):
Any sea-faring vessel that is going from one place to another is making a passage or 'passage-making'. It might also be at sea (not so much a technical term).
A seafaring vessel (of any kind) is under way (or underway) if it is:
- not aground
- not at anchor
- not made fast to a dock, the shore, or other stationary object.
If it is propelled (by any means including sails or engine but not including tidal drift or wind drift) then it is making way.
So a submarine under power would be under way - if it's not under power but it's also not moored or anchored or aground then it's under way, not making way.
If it is unable to maneuver (e.g. because its means of propulsion have failed) then it is not under command. This is typically a bad thing.
If it is sitting submerged on the seabed and can't get up again then it has sunk. Best to avoid this.
International Regulations for Preventing Collisions at Sea (on Wikisource)
Use of the terms 'under way' and 'making way' defined in "Farwell's Rules of the Nautical Road"
The BBC has used "sit in waters" in a news story:
Aside from attack capabilities, it is able to sit in waters off the coast undetected, delivering the UK's special forces where needed
but I think that sounds weird (personal opinion).