Hi there Amy, welcome to the forum!
A very interesting question! A year is the time it takes our planet to orbit the Sun, so on other planets, their year is different to ours as the planets take different amounts of time to orbit the Sun (or other stars).
But as for the passage of time in general, if you took a clock with you into space you would find that, wherever you are, the clock that is with you always ticks normally. So, wherever you go, a year would always last a year.
But....! Time is relative
, and one of the reasons is gravity.
Out in the depths of space, away from any source of gravity, a clock would tick at a faster rate when compared to a clock on Earth. So, from our point of view here on Earth, a year in deep space lasts less time than a year on Earth!
But how does that tie in with my statement that wherever you go, a year always lasts a year?
Well, if you live out in deep space, your year would be a normal year too, but a year on Earth would be longer than yours - a year on Earth lasts a longer period than a year in deep space!
Gravity affects how time passes. The larger the gravity the slower time passes when compared to
how time passes in a place with less gravity.
So a year in space is different than a year on Earth, and how much different depends on where you are. Near the Sun, a year is longer than on Earth, because there is more gravity around there than around here. But out beyond our Solar system, a year is shorter!
Wherever you are though, time passes at the normal rate for you, it is in other places where time is different!