A spit is a land form found off coasts. It forms when sediment builds up and a landmass is left. The sediment is deposited by waves. This is called longshore drift. When a spit forms, one end remains connected to the land while the other end exists in open water.
A salt marsh is "an environment between land and salty or brakish water, dominated by dense stands of salt-tolerant plants such as herbs, grasses or low shrubs." Salt marshes occur on low-energy coasts in temperate climates and high-latitudes.
A mudflat (aka tidal flats) is a coastal wetland that forms when mud is deposited by tides or rivers. "Mudflats may be viewed geologically as exposed layers of bay mud, resulting from deposition of estuarine silts, clays and marine animal detritus.
One of the main characteristics of the land forms necessary to form salt marshes is a low lying area near the ocean that is also protected from the ocean by something whether it is a beach or dunes or some other land form that regulates the amount of water flowing in and out but allows some of the ocean water to move inland. They often form around rivers or streams and their deltas near the confluence of the outgoing freshwater and incoming seawater during high tide.
They provide enormously important habitat and nutrient exchange zones for various fresh and salt water species of fish and other organisms as well as providing a place for a huge number of birds, etc.