It depends. MLA style minimizes the use of abbreviations in prose, but if in certain contexts the abbreviation is more common than the spelled out term, use the abbreviation. For example, you might refer to a 3-D movie rather than a three-dimensional movie, but you might write a two-dimensional surface rather than a 2-D surface.
If you are citing the title of a published work that includes the abbreviations, use the abbreviations. If you are supplying the title of your own work, be consistent: use whichever form—abbreviation or spelled-out term—that you have used in your paper.
Published 14 February 2019