Some call away and apart adverbs. They can be adverbs, but they don't always work that way, and they have different meanings and grammar.
All the examples of away and apart in the Original Question occur in measure phrases -- miles apart, two weeks away, three days apart, etc. These phrases involve a quantifier, either overt like two or understood like _(several) days, and a quantity like distance, time, weight, and optionally (as here) something that indicates specifics about the quantity that is being measured.
This something extra can be away, which means away from some zero point like now or here, and refers to the distance to be covered or the time to be expended (or the fare money to be collected, as in Chicago is $18 away) in traveling to a place. Away is asymmetric -- it only goes in one direction:
- Scranton is 30 minutes away (from Utopia)
means it takes 30 minutes to go (from Utopia) to Scranton.
- *Scranton and Utopia are 30 minutes away
is ungrammatical. Away requires a singular referent, not plural.
This extra thing can also be apart (as well as long, wide, tall, old, and many more). Apart comes from part and it is used to refer to things that occur together, as in the idioms come apart, rip apart, fall apart, etc.
In a measure phrase, apart requires a plural referent:
- Scranton and Utopia are 30 minutes apart
is perfectly grammatical, but
- *Scranton is 30 minutes apart from Utopia
As for what modifies what, don't worry about it.
The definition of adverbs they gave you is full of holes.