If you want to express that a set of items (or persons) are "the same", you should use the adjective isti:
Ovi auti su isti. "These cars are the same."
Sve ove lopte su iste. "All these balls are the same."
Bili smo u istom hotelu. "We were in the same hotel."
Keep in mind it's an adjective, that is, changes in case, gender and number according to the case, gender and number of nouns it describes.
If you want to express that one thing (or person) is "the same as" some other, add kao after isti:
Moj auto je isti kao tvoj. "My car is the same as yours."
The nom.sg.n isto is used as an adverb, roughly meaning "as well", "also"; it's use is a bit colloquial:
Mi smo isto došli jučer. "We came yesterday as well."
Recall that the same thing can be expressed with i.
The adjective jednak means "equal, identical" can be used to express a similar meaning.
There are several ways to express similarity in Croatian. First, it's possible to say that several things or people are similar, or that something is similar to something else, known before. The word used is the adjective sličän, meaning "similar", but also "alike", "looking alike":
Ovi auti su slični. "These cars are similar."
Ana i Ivana su slične. "Ana and Ivana look alike."
Ovaj problem je sličän. "This problem is similar."
If you want to express explicitly what or who is something or someone alike, you should specify it after the adjective, in dative:
Ana je slična Ivani(D). "Ana looks alike Ivana."
Moj auto je sličän tvom(D). "My car is similar to yours."
The nom.sg.n slično is used as an adverb:
[to be expanded]
The word kao means "as" or "like". It's a conjunction and can be used in various places, e.g. it can come before nouns:
Volim ga(A) kao brata(A). "I like him as a brother."
Volim je(A) kao prijateljicu(A). "I like her as a (female) friend."
Nouns after kao are put to the same case as ones you are comparing it to (it's acc. here, since volim requires acc.).
It can come before constructions with prepositions, adverbs, etc.:
Hladno je kao na Sjevernom polu. "It's cold like on the North Pole."
Hladno je kao zimi. "It's cold like in winter."
The word poput is similar to kao, but its use is much more restricted: it's a preposition, and the noun after it must be put in gen. It cannot be used before adverbs, constructs with prepositions, etc.
Next, it's possible to express similarity to an imaginary event or condition; this sounds complicated, but it's simple. In English, "as if" is used with 'subjunctive' (as in other 'if'-clauses in English, "were" instead of "is", past tense forms of other verbs, etc., but it's not always observed in practice):
"She behaves as if she were rich."
In Croatian, kao da is used, and there are no special tenses or moods involved:
Ponaša se kao da je bogata. "She behaves as if she were rich."
Mračno je kao da je noć. "It's dark as if it were night."
The second sentence sounds a bit stiff in English, but the Croatian one is perfectly normal and usual. Observe how present tense is used in Croatian! The clause after kao da is a NdaC, i.e. you can use any tense, but cannot use perf. verbs in the present tense:
[to be expanded]
As with other da-clauses, da occupies the first place in the clause and 'clitics' come right after it.
The examples above were with unreal situations: you know that she's not rich and it's not night.
Another, really different option is to express similarity to something real (or dissimilarity). In English, you would use just "as" (or a bit colloquially, "like"). In Croatian, you should use kao što:
Ana kuha juhu kao što je njena baka kuhala. "Ana cooks soup as her grandma cooked."
Frequently, "as" and kao što are simply a reference to an agreement, information, etc., not really a similarity; clauses with "as" or kao što are then put to the beginning:
Kao što säm vam rekao, sutra idemo u kino. "As I told you, tomorrow we're going to cinema."
Kao što vidite, restoran je pun. "As you can see, the restaurant is full."
In such use, instead of kao što, kako is sometimes used. Clauses after kao što are again of the NdaC type.
There are two words which are a kind of opposite: samo "only", and osim "except".
The word samo "just, only" restricts and emphasizes that "only" something was involved or done.
Pisao säm samo Ani. "I wrote only to Ana." (not to others)
Samo säm pisao Ani. "I only wrote to Ana." (I did nothing else)
This word is used in several phrases where it corresponds to English "just":
Samo malo! "Just a bit!" "Just a minute!"
Samo trenutak! "Just a moment!"
It's also used with imperatives, indicating that one should do action without hesitation:
Samo jëdi! "Just eat!"
Samo dođi! "Just come!"
The word is an adverb derived from the adjective sam "alone"; the nom.sg.n form of the adjective is exactly the same as the adverb:
Dijëte samo sjëdi. "The child sits alone." (samo = adjective)
This can lead to occasional confusion, when it's not clear if it's the adjective or the adverb, the previous sentence could be also understood as:
Dijëte samo sjëdi. "The child just sits." (samo = adverb)
However, if you place samo after the verb, it's normally understood as "alone". This confusion of course happens only for neuter nouns...
The word osim "except" excludes some phrase, so a wider context (where it is excluded from) must be also present or at least implied (often svi "all", svugdje "everywhere" etc.).
Bilo je lijëpo, osim kad je padala kiša. "It was nice, except when it rained."
Bili smo svugdjë, osim u muzeju. "We were everywhere, except in the museum."
Nouns after osim are put to the same case as if the noun is normally used in a sentence in the same role:
Pisao säm Ani(D). "I wrote to Ana."
Pisao säm svima(D), osim Ani(D). "I wrote to everyone, except Ana."
However, if osim is put before a noun (or noun phrase) in the would be normally in the nominative, the noun must be put into genitive:
Svi(N) su došli, osim Ane(G). "Everybody came, except Ana."
Svi(N) su otišli, osim mene(G). "Everybody came except me."