How to find Contact based on Phone Number instead of Email in Salesforce Embedded Service Deployment?

Use the following code in the Code Snippet. doFind and isExactMatch are set to false for Email, First Name and Last Name. But, doCreate is set to true for Email, First Name and Last Name because when the contact record is created, it will have the values passed from these fields. When the Chat is initiated, the contact is searched based on Phone number. If a matching Contact record is found, it will link it to the matched Contact record. Else, it will create a new Contact with the Last Name, First Name, Email and Phone Number entered.

Phone Field in Pre-Chat:
 
 
Sample Code:

        embedded_svc.settings.extraPrechatInfo = [ {
            "entityFieldMaps": [ {
                "doCreate": true,
                "doFind": true,
                "fieldName": "Phone",
                "isExactMatch": false,
                "label": "Phone"
                }, {
                "isExactMatch":false,
                "fieldName":"FirstName",
                "doCreate":true,
                "doFind":false,
                "label":"First Name"
                }, {
                "isExactMatch":false,
                "fieldName":"LastName",
                "doCreate":true,
                "doFind":false,
                "label":"Last Name"
                }, {
                "doCreate": true,
                "doFind": false,
                "fieldName": "Email",
                "isExactMatch": false,
                "label": "Email"
            } ],
            "entityName": "Contact"
        }];