What to do when there are defined constans in a module and you need to change it
Is there another way of doing? 


Depends where it's used. If the use is hardcoded into a function that doesn't offer any altering, then no, there's no other way other than a hack to change it.

Constants are constant, if they could be changed then they wouldn't be constant any more; if someone has used a constant they should have had a very good reason for doing so. So it's up to you to decide whether you trust the knowledge and design decision of the author. If you don't, don't use the module. Or change it to what you know is correct or reasonable.

At the very least, open an issue to ask the maintainer why they've hardcoded that value. There may have been a very good reason.