The term doctor is used for anyone with doctoral training (which includes PhD, EdD, MD, among others in the USA). This is why people tend to use the term "physician" to refer to medical doctors at some academic medical centers where there may be a lot of PhDs as well as MDs.