When citing records, treat the issuing agency as the author. The source’s title is the name of the item in which a record was found. Assuming the record was found in a database such as FamilySearch, or Ancestry, treat that as the container for the source, and if no publication date is given use the copyright dates of the website. For example, if you found a marriage certificate in an index of marriage certificates issued by New York City, covering 1907 through 1995 on Ancestry.com you would cite it like this:
In text:
According to documents, Obvious Fakename was married in 1922 (New York City).
Works Cited:
New York City, Marriage Indexes, 1907-1995. Ancestry, 1997-2020. www.ancestry.com/family-tree/person/tree/xxxxxxx/
person/xxxxxxxx/facts
[Adapted from https://style.mla.org/citing-documents-genealogy-sites/]