Q:

Modes of scales other than C major

I was learning modes. But I'm confused now. My problem is that I don't know how to apply the modes in other scale. For example I know in c major, mixolydian is form g to g and all keys are flat. But what is keys or notes should I play if I want mixolydian in d major scale?! Should I play c# and f# I this key or...?! 

A:

Modes are the result of playing a major scale but starting on a different degree. Here's how we derive all seven modes:
C-D-E-F-G-A-B-C
D-E-F-G-A-B-C-D
E-F-G-A-B-C-D-E
F-G-A-B-C-D-E-F
G-A-B-C-D-E-F-G
A-B-C-D-E-F-G-A
B-C-D-E-F-G-A-B
C-D-E-F-G-A-B-C

As you can see, there are seven different modes to be created from C major. But notice that these aren't only rearrangements of C major. We can think of them as scales in their own right!
C-D-E-F-G-A-B-C: C Ionian
D-E-F-G-A-B-C-D: D Dorian
E-F-G-A-B-C-D-E: E Phrygian
F-G-A-B-C-D-E-F: F Lydian
G-A-B-C-D-E-F-G: G mixolydian
A-B-C-D-E-F-G-A: A Aeolian
B-C-D-E-F-G-A-B: B Locrian

You also probably noticed that these aren't the same as the major scales on the root they have (except for Ionian, obviously). For example, D Dorian is not the same as D major. The word "Dorian" is therefore indicative of a different interval series! So how do we describe modes with relation to a major scale?
C-D-E-F-G-A-B-C: C major
D-E-F-G-A-B-C-D: D minor (♮6)
E-F-G-A-B-C-D-E: E minor (♭2)
F-G-A-B-C-D-E-F: F Major (♯4)
G-A-B-C-D-E-F-G: G major (♭7)
A-B-C-D-E-F-G-A: A minor
B-C-D-E-F-G-A-B: B minor (♭2,♭5)

Every mode can be thought of as an altered major or minor scale. To answer your question, "the mixolydian scale in D major" is a bit ambiguous. If you mean the mixolydian scale that is derived from D major, you mean A mixolydian (A-B-C♯-D-E-F♯-G-A). Notice it has the same notes as D major. If you meant a mixolydian scale built with D as the root, then that's just D mixolydian (D-E-F♯-G-A-B-C-D). One flattens the 7th scale degree (C♯) of D major to a ♭7 (C) to produce D mixolydian. 
In order to do what you described as "applying the modes", one simply plays each mode over the correct chord in a key. For example, in B major, when an F♯7 chord is being played, one can play F♯ mixolydian scales over it (because F♯ is the 5 of the key of B major). Same notes as B major, but a different way to use them. 

