The affiliation is mentioned based on the research work done. So if you carried out the data analysis or writing while your co-authors were affiliated to any organization, there is no problem in mentioning it, even they are retired from that organization. The best way is to mention when you carried out the work, in this way it is possible to validate if your co authors were working in that time in that particular institution.
If the co-author is not affiliated to any institution and if he is not the corresponding author, I will suggest to have him as independent research instead. It should not affect peer review or acceptance of your paper. Acceptance is based on the content not authors or affiliation.
My Ph.D. research supervisor and myself are about to publish a monograph. My research supervisor retired in 1995. I did my Ph.D in 1976. I retired in 2008 from an institution different from my research supervisor. We are mentioning our names, writing Retired Professor and mentioning the name of the institute where we worked last or worked for maximum number of years. The book contains material which was done on post retirement. No work was done in any Institute.