There's nothing wrong with adding your own answer, so long as it doesn't duplicate existing answers. If another answer basically has the solution, but has a lot of additional fluff, or is presented in a confusing manner, you're actually providing value if you add an answer that's simpler, or clearer. Don't focus on the fact that the other answer is confusing to you, unless it has actively misleading advice that should be called out.
Make sure to attribute the other answer if it was helpful in writing your own answer. Something like this should work:
This is based on Other User's answer ... [followed by the solution in your own words], [and additional information as relevant]
Note that you must link directly to the other answer (this is required by the license for all content on Stack Overflow). Generally, just make the text "Other User's answer" into a link to that answer. You can obtain a permalink to any post by clicking the "share" link below it, on the far left-hand side.
If some comments helped you form your answer, there's no harm in giving them credit as well, though comments are ephemeral, and may not last long. If you choose to attribute comments, you're better off quoting the comments directly:
As mentioned by Yet Another User
[whatever they said]
You can also include a link to the comment, if you choose. You can obtain a permalink to a comment by clicking on its timestamp.
Again, keep in mind that you should only add an answer if it adds value; i.e., you feel that the answer covers ground that is not covered in other answers and/or presents the material in a clearer fashion.