Do yourself a huge favor and meet with a corporate attorney and with a tax advisor before you do any work or take any money.
This is a general response to a general inquiry and is not intended to for any type of relationship, including but not limited to an attorney client relationship.
I am assuming by "foundation" you are referring to a tax exempt entity such as a private foundation or a public charity. It is not particularly complicated to form an entity to achieve this goal. You would need to form a not-for-profit corporation under state law and you would need to apply for tax exempt recognition from the IRS. The first step is very quick, the second is fairly lengthy (more than six months). However, you need not wait on recognition from the IRS before beginning operations. There are some risks by doing so. The IRS has plenty of helpful publications such as the one I have attached by link. This might make the process less overwhelming.