String function: Check phone number format.