## The creature trait, Limited Magic Immunity, can be difficult to adjudicate. 
But let's take a closer look.

If we look at the Rakshasa from the Basic Rules, it has this feature. 

> **Limited Magic Immunity.** The rakshasa can't be affected or detected by spells of 6th level or lower unless it wishes to be. It has advantage on saving throws against all other spells and magical effects.

There is an addition here, from the Monster Manual errata.

> Rakshasa (p. 257). Limited magic immunity: the first sentence now reads, “The rakshasa can’t be affected or detected by spells of 6th level or lower unless it wishes to be.”

I don’t know for sure what it said originally, but I suspect "detected" was added.

## Unofficial designer tweets
There are several tweets addressing questions about LMI, but they do not answer all questions, and sometimes create new ones. 

- Q - [Does a Rakshasa’s ‘Limited Magic Immunity’ protect it from weapons enhanced by Shillelagh?][1]
- A - *Shillelagh and magic weapon are spells. Limited Magic Immunity prevents a rakshasa from being affected by spells of 6th level or lower, unless it wishes to be.* - JC
- Q - [If I use divine Smite on a Rakshasa who has limited spell immunity, does he take any damage?][2]
- A - *don't believe it would be immune, since spell is affecting your weapon, not targeting rakshasa.* - MM
- Q - [Rakshasa can pass through Wall of Stone? It is immune of a Fire Elemental conjured by a 5th level Conjure Elemental?][3]
- A - *Because of the Limited Magic Immunity trait, a rakshasa could stroll through the wall created by the wall of stone spell, but not if the wall becomes permanent and nonmagical (aka undispellable).* - JC
- A2 - *A rakshasa's Limited Magic Immunity offers no protection against a summoned creature. The creature's presence is a spell effect. The creature itself is not a spell effect* - JC

The Mike Mearls comment seems to imply a spell targeting you (or your weapon) would still work, but that doesn't agree with Jeremy Crawford's answer regarding Magic Weapon. If we ignore MM's comment, this starts to give us a few more guidelines, like an instantaneous effect that doesn't last, or an effect with a duration would not affect the LMI target. 

## Reddit
There’s a [reddit post][4] with this [answer][5]. 

### Magic users have a whole brace of options against [a creature with Limited Magic Immunity].
- 7th level or above spells (*above the LMI threshold*)
- Summon spells
- Buff spells on other characters
- Defensive spells like counterspell and shield
- Spells that create an instantaneous effect that then later affects the Rakshasa, like a stone-shaped sword.
- Spells with a radius including the Rakshasha that continue to function at least partly as normal through the LMI such as silence. (The Rakshasa could still cast a spell as the silence does not affect them but the area still prevents all sound from escaping so functionally, they are still silent)

I tend to agree with most of this interpretation, although [Counterspell seems to be up for debate][6], and Shield probably wouldn't work, since although it's defensive, it is a spell effect that has a duration. So to answer your question,
> # Do Smite Spells work on Tiamat?

Although those spells have a range of self, they are not instantaneous, leaving a non-magical item, rather they are spell effects with a duration, so 
# No, but ask your DM.

But that doesn't mean all spells are useless. 

Further, you didn't ask, but since **Divine Smite**, the class feature isn't technically a spell, the answer is more difficult. One could argue they are fueled by spell slots and are "magical" in nature, but the ability specifically calls out spells, so in this case, I would imagine a DM may rule a creature with LMI, or specifically Tiamat, is **not immune**.  


  [1]: https://twitter.com/JeremyECrawford/status/932792921333493760?ref_src=twsrc%5Etfw%7Ctwcamp%5Etweetembed%7Ctwterm%5E932792921333493760%7Ctwgr%5Ef3b7db0f788a20e9e0236ae0d51547268a76d1b2%7Ctwcon%5Es1_&ref_url=https%3A%2F%2Fwww.sageadvice.eu%2Fdoes-a-rakshasas-limited-magic-immunity-protect-it-from-weapons-enhanced-by-shillelagh%2F
  [2]: https://twitter.com/Umasi_Isaku/status/987457809255157760?ref_src=twsrc%5Etfw%7Ctwcamp%5Etweetembed%7Ctwterm%5E987463477777215489%7Ctwgr%5E59c734a490df0e0c968d9781c9348ba9ae2abcdc%7Ctwcon%5Es2_&ref_url=https%3A%2F%2Fwww.sageadvice.eu%2Fif-i-use-divine-smite-on-a-rakshasa-who-has-limited-spell-immunity-does-he-take-any-damage%2F
  [3]: https://twitter.com/JeremyECrawford/status/1009572719732506624?ref_src=twsrc%5Etfw%7Ctwcamp%5Etweetembed%7Ctwterm%5E1009572719732506624%7Ctwgr%5E22b5e8d6c98438a8133465cb0840de6789da3017%7Ctwcon%5Es1_&ref_url=https%3A%2F%2Fwww.sageadvice.eu%2Frakshasa-can-pass-through-wall-of-stone-it-is-immune-of-a-fire-elemental-conjured-by-a-5th-level-conjure-elemental%2F
  [4]: https://www.reddit.com/r/dndnext/comments/37vv1l/question_about_limited_magic_immunity/
  [5]: https://www.reddit.com/r/dndnext/comments/37vv1l/comment/crqaoxh/?utm_source=share&utm_medium=web2x&context=3
  [6]: https://rpg.stackexchange.com/questions/67599/for-the-purpose-of-magic-immunity-does-counterspell-target-the-caster-or-the-sp