A dialect is the form of a language - which may have its own vocabulary, grammar and structures - spoken in a particular area . Thus, there are the Geordie dialect (with words such as 'netty' that are used virtually nowhere else)...the Aberdeen (Doric) dialect, the Cockney dialect and so on.
An accent is the way in which words are pronounced. So, the word 'off' in a posh/arisrocratic accent sounds like 'orff'...think of Prince Charles, for example, saying it. A cockney says 'my-be' when the rest of us say 'maybe'. A Glaswegian says 'heid' when the rest of us say 'head'...and so it goes on.
The two things, accent and dialect, are quite different. Thus, it is quite possible for someone to speak a piece of Geordie dialect in a Cornish accent!