Session state is user (session) specific while cache is global (same to all
sessions/users). Session also has different modes which impact on where
session state is persisted. (in memory i.e in-process, separate process,
database) This is to control the durability of sessions and so on for
example in case when application restarts when in-memory session state would
be lost. Cache data is also stored in-memory and it would be lost in case of
restart.
From programming perspective, their usage is similar. They are key/value
dictionaries/collections where you store/retrieve objects with a given key.