I had asked one question here. So as per answer I've written code, but I want someone to help me verify this custom code.
So should I post a new question or edit and place it in the existing question?
If in doubt, assume it's time to ask new question.
More specific: In your original question you needed a clue how to approach this problem. Now you have your code, and it is not working exactly the way you expected it. So it is a question about particular piece of code, new thing.
Of course it is always a good idea to link from new question to the old one, if anyone will ever want to verify why are you doing things the way you do or propose better way.
And thank you for asking in meta. If you would edit your question, it would became one of the hated "chameleon" questions no one likes. Better to ask first, than to get downvoted and then ask why.
Here is a discussion on network-wide meta you may want to read: Exit strategies for “chameleon questions”
Since the existing question already has an answer (which is then accepted), you need to ask that in a different question, as that is a different question, although it is a follow-up question. Even in the case the answer was not accepted, you should still ask a different question, since changing the question once it got an answer should be avoided. It is allowed to fix typos or grammar, or make the question clearer, but changing its meaning should not be done once it gets answers.
A question is not a ping-pong between the OP and the users who answer. Those questions continuously changing basing on the given answers are called chameleon questions, and are not welcome on Stack Exchange sites.
If you don't understand what the user is saying in the answer, you can ask in a comment, but asking something completely different should be done in a new question.