Your phone will be usually locked when you or someone enter incorrect password/passcode for multiple times. Your phone would do this to protect your information.
When you enter wrong password ***** multiple times, it should ask for the Gmail account associated with it. Is it asking for GMail account ? If so, then use that Gmail account to reset the code.
If it is not asking for Gmail, then the only option to get in to the phone is factory-reset it. Factory reset will erase everything from it and return it to new (like Out of Box). This is how they designed the device. Follow the steps below to factory reset it;
Turn off the phone
Press and hold down Volume Up and Power buttons at the same time for a few seconds.
Android system recovery will be loaded now
Select wipe data/factory reset. (Volume buttons to go up or down, select with Power button)
Select Yes — delete all user data.
Then select reboot system now
That should factory reset the phone . Please let me know if that didn't work, so we can continue troubleshooting.
Remember, this is not my final answer. If my solutions didn't work please don't rate me bad or poor. Instead please reply back to me and I will continue to help you until we fix the problem or you are satisfied.