I asked this question with genuine interest, supplied sufficient information about it, and showed that I have done prior research, but it still got downvoted a lot which is shocking to me. I was eager to find an answer to my question, but now I'm just demoralized. Why did it receive so much negativity and how can I avoid this next time?
The downvote tooltip (shown when you hover your cursor over the voting button) describes its intended use:
This question does not show any research effort; it is unclear or not useful
Think of these as "any" conditions rather than "all" conditions. If you think your question was clear and well-researched, then most likely the readers who voted it down considered it not to be useful.
This site is intended to be a problem-solving resource for people engaged in real projects and activities. Questions like "why do we do X instead of Y?" are usually based on a desire to engage in a conversation or satisfy some curiosity, either of which is fine in and of itself, but neither of which is directly related to solving an applied or practical problem.
Here's a quote from our Help Center article, What types of questions should I avoid asking?
You should only ask practical, answerable questions based on actual problems that you face. Chatty, open-ended questions diminish the usefulness of our site and push other questions off the front page.
This, in a nutshell, is why I agree that your question is not particularly valuable here. It's not a referendum on you as an individual; it sounds to me like you're a curious person, quantitatively-minded, and you genuinely want to explore the practical applications of electrolysis. There's nothing wrong with any of that, it's just not focused enough to be a good fit with our Q&A site.
A chat room or discussion forum would be a better venue for this sort of inquiry (see http://chat.stackexchange.com/).
As a general rule, users can use their votes however they like, short of outright abuse. So knowing why any individual downvoted you is impossible, unless they leave a comment explaining their vote.
Since we have some comments to look at, let's go ahead and speculate, for the sake of illustrating how this community (and many others on Stack Exchange) tends to evaluate questions.
Submarines and the ISS do this. I suspect carrying the quantity of batteries and kit required to do this would be impractical for a single diver.
The original version of the question claimed that "there never been any development in this direction." This comment points out that the claim is false. Three users upvoted it. Any of those four users might be of the opinion that you did insufficient research before asking, which is a likely motivation for downvoting.
This is an economics question, not an engineering question.
Users who don't think a question involves engineering will often downvote it, especially when the question is not so clearly off-topic that they feel comfortable voting to close.
And it ought to be a fairly obvious answer too.
Aren't you missing the glaringly obvious answer of "buoyancy?"
This site is designed to make experts happy, because experts provide the most useful solutions to practical problems. Experts sometimes feel that questions with trivial answers waste their time, particularly coming from curious laypeople with no real problem to solve, and will downvote to express that opinion.
I think your question is answerable (in short: it doesn't work because the battery is too weighty) and on-topic (what is engineering, if it isn't?). Furthermore, having nice ideas is always positive, even if they don't work.
Thus, although I think it is maybe not an academic level question, it is still useful and interesting. But it is only my opinion and it seems others opinion significantly differs in the matter.
Unfortunately, the SE is not a really motivating environment for young people with nice ideas. Don't let yourself to be disheartened, and don't make yourself an SE addict! It doesn't worth its price. And never stop thinking.
Note, your question will be soon probably closed. It is a different vote as your question count.
Try to follow the wishes of the community, but if it doesn't worth the effort, don't waste your time. It is your decision.
If you decide to remain, follow the advices of others. With time, things will be much easier.