I want to write a book about teachers experiences. It would be compiled of stories that other teachers have written to me. Do I have to give them credit in the book? What if I tell them their ideas submitted will be used in my book and all the names in their story will be changed. If they tell me the story knowing it is for my book, would I get sued later for copyright??
These other teachers have copyright rights to anything they've written, and you can't copy that work without their consent. If you want to use stories they've submitted to you, you need to get assignments from them for these stories.
They could also have "publicity rights" claims, if you use their images, names, signatures, etc. to sell your book, depending on what your state's publicity rights law says..
They could also have privacy rights claims, if you reveal personal facts about them, or present them in a "false light."
They might also have defamation claims, if you libel them by including provably false (not substantially true, even if not precisely accurate) facts (not opinions) about them. Changing their names won't immunizae you from this type of claim if they're recognizable by their descriptions.
If you want to use their stories as submitted or only do minor editing, you might want to share copyright authorship with them as co-contributors. The safest way to proceed is to see a lawyer about the appropriate way to compile and apportion rights to this work, and get any needed assignments and releases from these other contributors.
Disclaimer: Please note that this answer does not constitute legal advice, and should not be relied on, since each state has different laws, each situation is fact specific, and it is impossible to evaluate a legal problem without a comprehensive consultation and review of all the facts and documents at issue. This answer does not create an attorney-client relationship.