Your question is a bit vague. Have you got experience with MCU's sleeping before? It sounds like not.
Without looking into the specifics of the datasheet, the ASF page seems to describe a pretty generic sleep module.
There is usually a sleep() function that activates the sleep mode of the MCU. The MCU will stop execution at that instruction, and wait for a trigger to resume execution. There is also a mode select function that chooses how deep of a sleep state should be entered.
What the exact properties of each deep sleep state is, is written up in the datasheet and varies between MCU families and devices.
The main factor is what clocks are left running, and what you can still do with those clocks to wake the MCU up at some point. There may be several wake up sources of interest.
Usually MCU's will have an idle mode and deep sleep modes, possibly also several of both.
Idle usually turns of the CPU clock and keeps peripherals running. This is usually not any ultra-low power state by any means, but can shave off some power consumption if the MCU is primarily waiting for I/O transfers (like a peripheral interrupt or a DMA transfer). In idle mode the MCU can usually wake up from any interrupt source.
In the deeper sleep modes peripheral clocks are also turned off, meaning you can only wake up the MCU by specialized timers like watchdog, real-time counter or real-time clock/calendar peripheral. That is because usually the primary oscillator is turned off to save power. Additionally, you may need to take into account waking up from these deep sleep modes requires extra time, because the primary oscillator needs to be restarted. This is a trade-off between response-time (e.g. for ultra low power peripheral interrupts) and power consumption.
By looking at the ASF page, these 2 functions are of primary interest to you:
system_set_sleepmode(const enum system_sleepmode sleep_mode)
system_sleep(void)
Additionally you will need to set up peripherals in such a way that they will wake up the MCU when you need to, e.g. a watchdog timer that frequently wakes the MCU, or a RTC, or maybe even an external interrupt from an user button.