"I am going to keep that cake for myself."
Translation:Je vais garder ce gâteau pour moi.
This makes me think of the idiomatic proverb: "You can't have your cake and eat it, too." http://en.wikipedia.org/wiki/You_can%27t_have_your_cake_and_eat_it
French has more words than English when it comes to modifiers (determinants).
This and that are very versatile in English, but they can translate in a variety of French demonstratives, adjectives or pronouns.
In front of a noun, you need an adjective. This/that cake translates to "ce gâteau" where "ce" is a demonstrative adjective, masculine and singular.
"cet ami, cet homme" are masculine singular in front of a word starting with a vowel or a non aspirated H
"cette tarte" is feminine singular
"ces enfants" is masculine or feminine and plural.
When this or that are pronouns, you can translate them by "ceci", "cela" or "ça" which is the familiar abbreviation of "cela".
I will translate this = je traduirai ceci
that does not matter = cela ne fait rien / ça ne fait rien
"ça" is the shortened version of pronoun "cela". To modify a noun, you need an adjective (a pronoun replaces a noun), so demonstrative adjectives are:
masculine: ce or cet (in front of a word starting with a vowel or a non aspirate H)
plural masculine and feminine: ces
Your sentence "Je vais me garder ce gâteau" is written in too familiar language. In correct French we can say :
"se garder de quelqu'un" (to beware of somebody)
"se garder de faire quelque chose" : (to take care to do something)
"se garder à trèfle" (to keep a covering card in clubs)
"cette viande ne se garde pas bien" (this meat does not keep well)
but we cannot say "Je me garde quelque chose", we have to say "Je garde quelque chose pour moi".