Foreigners are allowed to open a bank account in Thailand. However, it might not be as easy as it looks. Different banks and even different branches of the same bank might have different requirements. Even worse, at the same branch, two different employees can have different visions about what is required and how to do it!
Bank accounts can be opened in Thai baht or in foreign currency. You don't necessarily have to LIVE in Thailand to have a bank account but a bank might ask you some proof of residence, from a work permit, a Thai driving license or a document from the Immigration office.
Example: BANGKOK BANK
According to their website, "foreigners with a long stay visa, work permit or even a tourist visa can open a savings account with Bangkok Bank at any of their branches nationwide." The Bangkok bank website is quite complete in English and it's just easier for us to explain you how it works for that bank.
According to Bangkok Bank, if you are working in Thailand, you will need your passport AND work permit.
If you are living in Thailand with a long stay visa, you will need your passport AND a proof of residence, like a certificate of residence from immigration or a house registration book for foreigners.
If you are in Thailand for a short stay or have a tourist visa, then you will need more documents:
Again, in practice, a local branch could accept your driving license with a picture or other documents. By experience, we know that it's normally easier for foreigners to open a bank account at Kasikorn bank. You normally just have to show a passport and no work permit is required.
Once the bank account is open, it's normally easy to get an ATM card. Internet banking will normally require some additional forms and again, each bank is different. And if you are looking for a clear answer, you might just have several different from bank employees.
This is Thailand!