android security question

So some apps need a permission to check phone state why is this needed and 2 with this permission the app can find out your phone number my main question is if the app is from a trusted company will the app find your number or is it only if its a app with the permission that contains malware.