then how come the same dataset is created in JCL?
Please clarify - i do not understand the question.
Why is the process trying to create generation 1 (g0001v00) again? Typically, new generations are created as a (+1) and "the next" generation is assigned?
If this is a gdg, the jcl may need to be corrected to use the next relative generation rather than and absolute 1. It may help if you post the actual jcl.