Generally, you cannot change anything after publication. At that point the hardcopies might already be printed, the electronic versions will already have been distributed, and so on. If you must make changes, you'll have to issue an erratum or corrigendum - see the journal's website on their policies for this.
After acceptance but before publication (as well as after submission but before acceptance), then it's still possible to change. The difference between the two scenarios is that after acceptance you're probably liaising with the publisher, while before it you're probably liaising with the editorial board of the journal. However practically speaking there should be little difference: both are likely to accept acknowledgements changes without much thought, while requesting an explanation for author changes.
To change the acknowledgements after acceptance, just request the extra text when the publisher shows you the proofs. To change it before acceptance, do it if the manuscript receives a decision of 'revise', with a small note on the change in the response to reviewers. If your paper is accepted without revisions, then just change it during the proofs stage. Changing authors is similar, but be ready with an explanation. You might also be asked for a letter signed by all other co-authors, per Mark's answer.